none
General Questions RRS feed

  • Question

  • Hi everyone,

    I have a few questions about SmallBasic, how a few things work.

    1. What is included with the SmallBasic.dll, why is this needed if it uses .net?

    2. Is the graphics window just a form and how does it handle it's images does it use hardware/directx?

    Wednesday, June 8, 2011 11:18 PM

Answers

  • I am not sure about direct hardware acceleration but output is same.

    Because small basic has feature to translate code to Visual Basic I would say the compiler first translates code to Visual Basic and compiles Visual Basic code to exe using compiler inside .Net Framework. Anyway the output is same than exe made with C# or VB. Small Basic Compiler just generates missing code like entry point and main class.


    Sorry My Bad English
    • Marked as answer by Kirkkaf Saturday, June 11, 2011 2:19 PM
    Friday, June 10, 2011 6:06 AM

All replies

  • 1: Inside the SmallBasic.dll are the libraries you see when you type in your code. According to what I read on .NET at this link, I guess it uses .NET for the interface, and some other stuff.

    2: I don't think SmallBasic uses DirectX, because it is not required for installation. I think that the GraphicsWindow handles its images like it the VB windows would.


    ~~AirWaves!!~~
    Thursday, June 9, 2011 3:53 AM
  • Thanks for your reply AirWaves.

     

    It would be alot better if the .dlls are packed straight into the executable file as I think some languages do e.g purebasic as I don't have to ship libraries with my program.

    DirectX might not be used as you said but what kind of technique is used to draw shapes/images to a form and move/animate them without drawing to a backbuffer to stop flickering and clearing the form to stop the shape/image being dragged across the screen.

    EDITED: As SmallBasic uses the .net framework which alot of other languages do now days. It doesn't get compiled to machine code then uses the CLR common language runtime to interpret the language to something the computer understands. If this is the case then once compiled the output should be the same as any other .net language and should only need .net framework to handle the interpreting once compiled.

    Thanks. 


    Thursday, June 9, 2011 7:02 AM
  • Small Basic uses .net and WPF to create graphics not Windows Forms or DirectX (directly). DirectX installation is not required because it ships with operating systems and service packs.

    With .dll packing you are right. Output from Small Basic Compiler could be portable exe that contains program, SmallBasicLibrary.dll and extensions but that feature requires few extra tricks from compiler. But even if you have portable exe it still requires .Net Framework.

    When Microsoft Small Basic uses .Net Framework programs created with small basic doesn't work on Linux and Mac.


    Sorry My Bad English
    Thursday, June 9, 2011 8:04 AM
  • Thanks for your response.

     

    So WPF utilizes DirectX to allow 2d and 3d rendering? Would it be correct saying SmallBasic is hardware accelerated?

    When SmallBasic is compiled what is the output, is it the same as VB.NET and C#?

    Thursday, June 9, 2011 8:29 PM
  • I am not sure about direct hardware acceleration but output is same.

    Because small basic has feature to translate code to Visual Basic I would say the compiler first translates code to Visual Basic and compiles Visual Basic code to exe using compiler inside .Net Framework. Anyway the output is same than exe made with C# or VB. Small Basic Compiler just generates missing code like entry point and main class.


    Sorry My Bad English
    • Marked as answer by Kirkkaf Saturday, June 11, 2011 2:19 PM
    Friday, June 10, 2011 6:06 AM
  • Thanks for the information.
    Saturday, June 11, 2011 2:19 PM