'' ----------------------------------------------------------------------------
'' Irrlicht Wrapper For Imperative Languages - Freebasic Examples
'' Frank Dodd (2006-2010)
'' ----------------------------------------------------------------------------
'' Blitz-Irrlicht 1.8.3 Interface by Ed Musolino (AquaLung 2015)
'' ----------------------------------------------------------------------------
'' Example 01: Hello World
'' This simple example opens an Irrlicht window And displays the Text
'' Hello World on the screen And waits For the user To close the application
'' ----------------------------------------------------------------------------

'' ////////////////////////////////////////////////////////////////////////////
'' Includes For extension libraries
Framework usr.birrlicht

'' ////////////////////////////////////////////////////////////////////////////
'' Global variables

'' ////////////////////////////////////////////////////////////////////////////
' -----------------------------------------------------------------------------
' start the irrlicht interface. The scene will be rendered using the Irrlicht,
' software renderer, the display will be a window 400 x 200 pixels in size, the
' display will Not support shadows And we will Not capture any keyboard And
' mouse events And finally vertical syncronisation To smoothen the display
' is switched on, by Default it is off
iIrr3D( 640, 480, 32, False )

' Set the title of the display
iAppTitle( "Example 01: Hello World" )

' add a static Text Object To the graphical user interface. The Text will be
' drawn inside the defined rectangle, the box will Not have a border And the
' Text will Not be wrapped around If it runs off the End
iStaticText( "Hello World", 4,0,200,16, IRR_GUI_NO_BORDER, IRR_GUI_NO_WRAP ,0)

' erase the canvas To white before rendering
iCameraCLSColor( 255, 255, 255 )

' While the scene is still running
While iRun() And (Not iKeyHit(KEY_ESCAPE))
    ' begin the scene
    iBeginScene()

    ' draw the Graphical User Interface
    iDrawGUI()

    ' End drawing the scene And render it
    iEndScene()
Wend

' -----------------------------------------------------------------------------
' Stop the irrlicht engine And Release resources
iEndIrr3D()

End