'' ----------------------------------------------------------------------------
'' Blitz \ Irrlicht 1.8.3 Interface by Ed Musolino Jr (2015) {AquaLung}
'' Based off of Frank Dodd's Irrlicht 1.7.1 Freebasic Wrapper (2006-2010)
'' ----------------------------------------------------------------------------

''  This software is provided 'as-is', without any express Or implied
''  warranty.  In no event will the authors be held liable For any damages
''  arising from the use of this software.

''  Permission is granted To anyone To use this software For any purpose,
''  including commercial applications, And To redistribute it
''  freely, subject To the following restrictions:

''  1. The Origin of this software must Not be misrepresented; you must Not
''     claim that you wrote the original software. If you use this software
''     in a product, an acknowledgement in the product documentation would be
''     appreciated but is Not required.
''  2. This notice may Not be removed Or altered from any source distribution.
''
'' /////////////////////////////////////////////////////////////////////////////

Strict
Import brl.system
Import pub.win32

Rem
bbdoc: Irrlicht/bIrrlicht Library
End Rem
Module usr.bIrrlicht

ModuleInfo "Version: 2.0.0.0"
ModuleInfo "Author: Ed Musolino ( AquaLung )"
ModuleInfo "License: SEE DETAILS"
ModuleInfo "Modserver: USER"
ModuleInfo "Credit: Adapted for BlitzMax by Ed Musolino"

' --------------------
' DLL Loading and init
' --------------------
Const IrrlichtWrapperDllName:String = "bIrrlicht.dll"
Local DllHandle:Int = LoadLibraryA(IrrlichtWrapperDllName)

If DLLhandle = 0 Then
	RuntimeError "Unable to initialize dll : "+IrrlichtWrapperDllName
	End
EndIf

'' ////////////////////////////////////////////////////////////////////////////
'' Enumerated Type Definitions

' Rendering Device Types
'ENUM IRR_DEVICE_TYPES
Const IRR_EDT_NULL:Int = 0       	        ' a Null device with no display
Const IRR_EDT_SOFTWARE:Int = 1            ' Irrlichts Default software renderer
Const IRR_EDT_SOFTWARE2:Int = 2           ' An improved quality software renderer
Const IRR_EDT_OPENGL:Int = 3              ' hardware accelerated OpenGL renderer
Const IRR_EDT_DIRECT3D8:Int = 5           ' hardware accelerated DirectX 8 renderer * Not AVAILABLE
Const IRR_EDT_DIRECT3D9:Int = 5           ' hardware accelerated DirectX 9 renderer

' Material Flags
'ENUM IRR_MATERIAL_FLAGS
Const IRR_EMF_WIREFRAME:Int = 0     	    ' Render as wireframe outline.
Const IRR_EMF_POINTCLOUD:Int = 1           ' Draw a point cloud instead of polygons.
Const IRR_EMF_GOURAUD_SHADING:Int = 2      ' Render smoothly across polygons.
Const IRR_EMF_LIGHTING:Int = 3             ' Material is effected by lighting.
Const IRR_EMF_ZBUFFER:Int = 4              ' Enable z-buffer.
Const IRR_EMF_ZWRITE_ENABLE:Int = 5        ' Can write as well as read z-buffer.
Const IRR_EMF_BACK_FACE_CULLING:Int = 6    ' Cull polygons facing away.
Const IRR_EMF_FRONT_FACE_CULLING:Int = 7   ' Cull polygons facing front.
Const IRR_EMF_BILINEAR_FILTER:Int = 8      ' Enable bilinear filtering.
Const IRR_EMF_TRILINEAR_FILTER:Int = 9     ' Enable trilinear filtering.
Const IRR_EMF_ANISOTROPIC_FILTER:Int = 10  ' Reduce blur in distant textures.
Const IRR_EMF_FOG_ENABLE:Int = 11          ' Enable fogging in the distance.
Const IRR_EMF_NORMALIZE_NORMALS:Int = 12   ' Use when scaling dynamically lighted models.
Const IRR_EMF_TEXTURE_WRAP:Int = 13        ' Gives access To all layers texture wrap settings.
										' Overwrites separate layer settings. 
Const IRR_EMF_ANTI_ALIASING:Int = 14       ' Anti-aliasing mode. 
Const IRR_EMF_COLOR_MASK:Int = 15          ' ColorMask bits, For enabling the color planes. 
Const IRR_EMF_COLOR_MATERIAL:Int = 16      ' ColorMaterial enum For vertex color interpretation. 

' Material Types
'ENUM IRR_MATERIAL_TYPES
Const IRR_EMT_SOLID:Int = 0               ' Standard solid rendering uses one texture
Const IRR_EMT_SOLID_2_LAYER:Int = 1       ' 2 blended textures using vertex alpha value
Const IRR_EMT_LIGHTMAP:Int = 2            ' 2 textures: 0=color 1=lighting level And ignores vertex lighting
Const IRR_EMT_LIGHTMAP_ADD:Int = 3        ' ... as above but adds levels instead of modulating between them
Const IRR_EMT_LIGHTMAP_M2:Int = 4         ' ... as above but color levels are multiplied by 2 For brightening
Const IRR_EMT_LIGHTMAP_M4:Int = 5         ' ... as above but color leels are multiplied by 4 For brightening
Const IRR_EMT_LIGHTMAP_LIGHTING:Int = 6   ' 2 textures: 0=color 1=lighting level but supports dynamic lighting
Const IRR_EMT_LIGHTMAP_LIGHTING_M2:Int = 7    ' ... as above but color levels are multiplied by 2 For brightening
Const IRR_EMT_LIGHTMAP_LIGHTING_M4:Int = 8    ' ... as above but color leels are multiplied by 4 For brightening
Const IRR_EMT_DETAIL_MAP:Int = 9          ' 2 blended textures: the first is a color map the second at a different scale adds And subtracts from the color To add detail
Const IRR_EMT_SPHERE_MAP:Int = 10          ' makes the material appear reflective
Const IRR_EMT_REFLECTION_2_LAYER:Int = 11  ' a reflective material blended with a color texture
Const IRR_EMT_TRANSPARENT_ADD_COLOR:Int = 12   ' a transparency effect that simply adds a color texture To the background. the darker the color the more transparent it is.
Const IRR_EMT_TRANSPARENT_ALPHA_CHANNEL:Int = 13   ' a transparency effect that uses the color textures alpha as a transparency level
Const IRR_EMT_TRANSPARENT_ALPHA_CHANNEL_REF:Int = 14   ' a transparency effect that uses the color textures alpha, the pixel is only drawn If the alpha is > 127. this is a fast effect that does Not blur edges And is ideal For leaves & grass etc.
Const IRR_EMT_TRANSPARENT_VERTEX_ALPHA:Int = 15    ' a transparency effect that uses the vertex alpha value
Const IRR_EMT_TRANSPARENT_REFLECTION_2_LAYER:Int = 16  ' a transparent & reflecting effect. the first texture is a reflection map, the second a color map. transparency is from vertex alpha
Const IRR_EMT_NORMAL_MAP_SOLID:Int = 17    ' A solid normal map renderer. First texture is color, second is normal map. Only use nodes added with IrrAddStaticMeshForNormalMappingToScene. Only supports nearest two lights. Requires vertex And pixel shaders 1.1
Const IRR_EMT_NORMAL_MAP_TRANSPARENT_ADD_COLOR:Int = 18    ' ... as above only with a transparency effect that simply adds the color To the background. the darker the color the more transparent it is.
Const IRR_EMT_NORMAL_MAP_TRANSPARENT_VERTEX_ALPHA:Int = 19 ' ... as above only with a transparency effect that uses the vertex alpha value
Const IRR_EMT_PARALLAX_MAP_SOLID:Int = 20  ' similar To the solid normal map but more realistic providing virtual displacement of the surface. Uses the alpha channel of the normal map For height Field displacement. Requires vertex shader 1.1 And pixel shader 1.4.
Const IRR_EMT_PARALLAX_MAP_TRANSPARENT_ADD_COLOR:Int = 21  ' ... as above only with a transparency effect that simply adds the color To the background. the darker the color the more transparent it is.
Const IRR_EMT_PARALLAX_MAP_TRANSPARENT_VERTEX_ALPHA:Int = 22   ' ... as above only wiht a transparency effect that uses the vertex alpha value
Const IRR_EMT_ONE_TEXTURE_BLEND:Int = 23
Const IRR_EMT_FORCE_32BIT:Int = $7fffffff

' blend factors For the ONE_TEXTURE_BLEND material
'ENUM IRR_BLEND_FACTOR
Const EBF_ZERO:Int = 0
Const EBF_ONE:Int = 1
Const EBF_DST_COLOR:Int = 2
Const EBF_ONE_MINUS_DST_COLOR:Int = 3
Const EBF_SRC_COLOR:Int = 4
Const EBF_ONE_MINUS_SRC_COLOR:Int = 5
Const EBF_SRC_ALPHA:Int = 6
Const EBF_ONE_MINUS_SRC_ALPHA:Int = 7
Const EBF_DST_ALPHA:Int = 8
Const EBF_ONE_MINUS_DST_ALPHA:Int = 9
Const EBF_SRC_ALPHA_SATURATE:Int = 10          

' Mouse events
'ENUM IRR_MOUSE_EVENTS
Const IRR_EMIE_LMOUSE_PRESSED_DOWN:Int = 0
Const IRR_EMIE_RMOUSE_PRESSED_DOWN:Int = 1
Const IRR_EMIE_MMOUSE_PRESSED_DOWN:Int = 2
Const IRR_EMIE_LMOUSE_LEFT_UP:Int = 3
Const IRR_EMIE_RMOUSE_LEFT_UP:Int = 4
Const IRR_EMIE_MMOUSE_LEFT_UP:Int = 5
Const IRR_EMIE_MOUSE_MOVED:Int = 6
Const IRR_EMIE_MOUSE_WHEEL:Int = 7
Const IRR_LMOUSE_BUTTON:Int = 1
Const IRR_RMOUSE_BUTTON:Int = 2
Const IRR_MMOUSE_BUTTON:Int = 3

' Event types
'enum IRR_EEVENT_TYPE
Const IRR_EET_GUI_EVENT           :Int = 0
Const IRR_EET_MOUSE_INPUT_EVENT   :Int = 1
Const IRR_EET_KEY_INPUT_EVENT     :Int = 2
Const IRR_EET_JOYSTICK_INPUT_EVENT:Int = 3
Const IRR_EET_LOG_TEXT_EVENT      :Int = 4
Const IRR_EET_USER_EVENT          :Int = 5

' MD2 Animation sequences
'ENUM IRR_MD2_ANIM_SEQUENCES
Const IRR_EMAT_STAND:Int = 0
Const IRR_EMAT_RUN:Int = 1
Const IRR_EMAT_ATTACK:Int = 2
Const IRR_EMAT_PAIN_A:Int = 3
Const IRR_EMAT_PAIN_B:Int = 4
Const IRR_EMAT_PAIN_C:Int = 5
Const IRR_EMAT_JUMP:Int = 6
Const IRR_EMAT_FLIP:Int = 7
Const IRR_EMAT_SALUTE:Int = 8
Const IRR_EMAT_FALLBACK:Int = 9
Const IRR_EMAT_WAVE:Int = 10
Const IRR_EMAT_POINT:Int = 11
Const IRR_EMAT_CROUCH_STAND:Int = 12
Const IRR_EMAT_CROUCH_WALK:Int = 13
Const IRR_EMAT_CROUCH_ATTACK:Int = 14
Const IRR_EMAT_CROUCH_PAIN:Int = 15
Const IRR_EMAT_CROUCH_DEATH:Int = 16
Const IRR_EMAT_DEATH_FALLBACK:Int = 17
Const IRR_EMAT_DEATH_FALLFORWARD:Int = 18
Const IRR_EMAT_DEATH_FALLBACKSLOW:Int = 19
Const IRR_EMAT_BOOM:Int = 20

' MD3 Animation Sequences
'ENUM IRR_EMD3_ANIMATION_TYPE
Const IRR_EMD3_BOTH_DEATH_1:Int = 0
Const IRR_EMD3_BOTH_DEAD_1:Int = 1
Const IRR_EMD3_BOTH_DEATH_2:Int = 2
Const IRR_EMD3_BOTH_DEAD_2:Int = 3
Const IRR_EMD3_BOTH_DEATH_3:Int = 4
Const IRR_EMD3_BOTH_DEAD_3:Int = 5
Const IRR_EMD3_TORSO_GESTURE:Int = 6	
Const IRR_EMD3_TORSO_ATTACK_1:Int = 7
Const IRR_EMD3_TORSO_ATTACK_2:Int = 8
Const IRR_EMD3_TORSO_DROP:Int = 9
Const IRR_EMD3_TORSO_RAISE:Int = 10
Const IRR_EMD3_TORSO_STAND_1:Int = 11
Const IRR_EMD3_TORSO_STAND_2:Int = 12
Const IRR_EMD3_LEGS_WALK_CROUCH:Int = 13	
Const IRR_EMD3_LEGS_WALK:Int = 14
Const IRR_EMD3_LEGS_RUN:Int = 15
Const IRR_EMD3_LEGS_BACK:Int = 16
Const IRR_EMD3_LEGS_SWIM:Int = 17
Const IRR_EMD3_LEGS_JUMP_1:Int = 18
Const IRR_EMD3_LEGS_LAND_1:Int = 19
Const IRR_EMD3_LEGS_JUMP_2:Int = 20
Const IRR_EMD3_LEGS_LAND_2:Int = 21
Const IRR_EMD3_LEGS_IDLE:Int = 22
Const IRR_EMD3_LEGS_IDLE_CROUCH:Int = 23 	
Const IRR_EMD3_LEGS_TURN:Int = 24
Const IRR_EMD3_ANIMATION_COUNT:Int = 25

'ENUM IRR_EMD3Models
Const IRR_EEMD3_HEAD:Int = 0
Const IRR_EEMD3_UPPER:Int = 1
Const IRR_EEMD3_LOWER:Int = 2
Const IRR_EEMD3_WEAPON:Int = 3
Const IRR_EEMD3_NUMMODELS:Int = 4

' For the FPS camera
'Enum EKEY_ACTION
Const EKA_MOVE_FORWARD:Int = 0
Const EKA_MOVE_BACKWARD:Int = 1
Const EKA_STRAFE_LEFT:Int = 2
Const EKA_STRAFE_RIGHT:Int = 3
Const EKA_JUMP_UP:Int = 4
Const EKA_COUNT:Int = 5
Const EKA_FORCE_32BIT:Int = $7fffffff

' Light types
'Enum E_LIGHT_TYPE
Const ELT_POINT:Int = 0
Const ELT_SPOT:Int = 1
Const ELT_DIRECTIONAL:Int = 2

' Joint animation modes
'Enum IRR_JOINT_MODE
Const IRR_JOINT_MODE_NONE:Int = 0
Const IRR_JOINT_MODE_READ:Int = 1
Const IRR_JOINT_MODE_CONTROL:Int = 2

' shadow modes For lighting
'Enum E_SHADOW_MODE
Const ESM_RECEIVE:Int = 0
Const ESM_CAST:Int = 1
Const ESM_BOTH:Int = 2
Const ESM_EXCLUDE:Int = 3
Const ESM_COUNT:Int = 4

' filter types, up To 16 samples PCF.
'Enum E_FILTER_TYPE
Const EFT_NONE:Int = 0
Const EFT_4PCF:Int = 1
Const EFT_8PCF:Int = 2
Const EFT_12PCF:Int = 3
Const EFT_16PCF:Int = 4
Const EFT_COUNT:Int = 5

' Pre-programmed shader constants
'Enum IRR_SHADER_CONSTANTS
Const IRR_NO_PRESET:Int = 0
Const IRR_INVERSE_WORLD:Int = 1
Const IRR_WORLD_VIEW_PROJECTION:Int = 2
Const IRR_CAMERA_POSITION:Int = 3
Const IRR_TRANSPOSED_WORLD:Int = 4

' Vertex shader program versions
'Enum IRR_VERTEX_SHADER_VERSION
Const EVST_VS_1_1:Int = 0
Const EVST_VS_2_0:Int = 1
Const EVST_VS_2_a:Int = 2
Const EVST_VS_3_0:Int = 3

' Pixel shader program versions
'Enum IRR_PIXEL_SHADER_VERSION
Const EPST_PS_1_1:Int = 0
Const EPST_PS_1_2:Int = 1
Const EPST_PS_1_3:Int = 2
Const EPST_PS_1_4:Int = 3
Const EPST_PS_2_0:Int = 4
Const EPST_PS_2_a:Int = 5
Const EPST_PS_2_b:Int = 6
Const EPST_PS_3_0:Int = 7

' enumeration For querying features of the video driver. 
'Enum IRR_VIDEO_FEATURE_QUERY
    ' Is driver able To render To a surface?
Const EVDF_RENDER_TO_TARGET:Int = 0
    
    ' Is hardeware transform And lighting supported?
Const EVDF_HARDWARE_TL:Int = 1
    
    ' Are multiple textures per material possible?
Const EVDF_MULTITEXTURE:Int = 2
    
    ' Is driver able To render with a bilinear filter applied?
Const EVDF_BILINEAR_FILTER:Int = 3
    
    ' Can the driver handle mip maps?
Const EVDF_MIP_MAP:Int = 4
    
    ' Can the driver update mip maps automatically?
Const EVDF_MIP_MAP_AUTO_UPDATE:Int = 5
    
    ' Are stencilbuffers switched on And does the device support stencil buffers?
Const EVDF_STENCIL_BUFFER:Int = 6
    
    ' Is Vertex Shader 1.1 supported?
Const EVDF_VERTEX_SHADER_1_1:Int = 7
    
    ' Is Vertex Shader 2.0 supported?
Const EVDF_VERTEX_SHADER_2_0:Int = 8
    
    ' Is Vertex Shader 3.0 supported?
Const EVDF_VERTEX_SHADER_3_0:Int = 9
    
    ' Is Pixel Shader 1.1 supported?
Const EVDF_PIXEL_SHADER_1_1:Int = 10
    
    ' Is Pixel Shader 1.2 supported?
Const EVDF_PIXEL_SHADER_1_2:Int = 11
    
    ' Is Pixel Shader 1.3 supported?
Const EVDF_PIXEL_SHADER_1_3:Int = 12
    
    ' Is Pixel Shader 1.4 supported?
Const EVDF_PIXEL_SHADER_1_4:Int = 13
    
    ' Is Pixel Shader 2.0 supported?
Const EVDF_PIXEL_SHADER_2_0:Int = 14
    
    ' Is Pixel Shader 3.0 supported?
Const EVDF_PIXEL_SHADER_3_0:Int = 15
    
    ' Are ARB vertex programs v1.0 supported?
Const EVDF_ARB_VERTEX_PROGRAM_1:Int = 16
    
    ' Are ARB fragment programs v1.0 supported?
Const EVDF_ARB_FRAGMENT_PROGRAM_1:Int = 17
    
    ' Is GLSL supported?
Const EVDF_ARB_GLSL:Int = 18
    
    ' Is HLSL supported?
Const EVDF_HLSL:Int = 19
    
    ' Are non-square textures supported?
Const EVDF_TEXTURE_NSQUARE:Int = 20
    
    ' Are non-power-of-two textures supported?
Const EVDF_TEXTURE_NPOT:Int = 21
    
    ' Are framebuffer objects supported?
Const EVDF_FRAMEBUFFER_OBJECT:Int = 22
    
    ' Are vertex buffer objects supported?
Const EVDF_VERTEX_BUFFER_OBJECT:Int = 23
    
    ' Supports Alpha To Coverage
Const EVDF_ALPHA_TO_COVERAGE:Int = 24
    
    ' Supports Color masks (disabling color planes in output)
Const EVDF_COLOR_MASK:Int = 25
    
    ' Supports multiple render targets at once
Const EVDF_MULTIPLE_RENDER_TARGETS:Int = 26
    
    ' Supports separate blend settings For multiple render targets
Const EVDF_MRT_BLEND:Int = 27
    
    ' Supports separate color masks For multiple render targets
Const EVDF_MRT_COLOR_MASK:Int = 28
    
    ' Supports separate blend functions For multiple render targets
Const EVDF_MRT_BLEND_FUNC:Int = 29
    
    ' Supports geometry shaders
Const EVDF_GEOMETRY_SHADER:Int = 30

' Enumeration flags defining the file format supported loading And saving
'Enum IRR_MESH_FILE_FORMAT
Const EMWT_IRR_MESH:Int = 0            ' Irrlicht Native mesh writer, For static .irrmesh files.  
Const EMWT_COLLADA:Int = 1                 ' COLLADA mesh writer For .dae And .xml files.  
Const EMWT_STL:Int = 2                     ' STL mesh writer For .stl files.  

' Enumeration flags defining the size of a patch in the terrain
'Enum IRR_TERRAIN_PATCH_SIZE
Const ETPS_9:Int = 9                    ' patch size of 9, at most, use 4 levels of detail with this patch size.  
Const ETPS_17:Int = 17                  ' patch size of 17, at most, use 5 levels of detail with this patch size.  
Const ETPS_33:Int = 33                  ' patch size of 33, at most, use 6 levels of detail with this patch size.  
Const ETPS_65:Int = 65                  ' patch size of 65, at most, use 7 levels of detail with this patch size.  
Const ETPS_129:Int = 129                ' patch size of 129, at most, use 8 levels of detail with this patch size. 

' Enumeration flags telling the video driver in which format textures should be created. 
'Enum IRR_TEXTURE_CREATION_FLAG
Const ETCF_ALWAYS_16_BIT         :Int = $1'&h1  ' Forces the driver To Create 16 bit textures always, independent of which format the file on disk has. When choosing this you may loose some color detail, but gain much speed And memory. 16 bit textures can be transferred twice as fast as 32 bit textures And only use half of the space in memory. When using this flag, it does Not make sense To use the flags ETCF_ALWAYS_32_BIT, ETCF_OPTIMIZED_FOR_QUALITY, Or ETCF_OPTIMIZED_FOR_SPEED at the same time.  
Const ETCF_ALWAYS_32_BIT         :Int = $2  ' Forces the driver To Create 32 bit textures always, independent of which format the file on disk has. Please note that some drivers (like the software device) will ignore this, because they are only able To Create And use 16 bit textures. When using this flag, it does Not make sense To use the flags ETCF_ALWAYS_16_BIT, ETCF_OPTIMIZED_FOR_QUALITY, Or ETCF_OPTIMIZED_FOR_SPEED at the same time.  
Const ETCF_OPTIMIZED_FOR_QUALITY :Int = $4  ' Lets the driver decide in which format the textures are created And tries To make the textures look as good as possible. Usually it simply chooses the format in which the texture was stored on disk. When using this flag, it does Not make sense To use the flags ETCF_ALWAYS_16_BIT, ETCF_ALWAYS_32_BIT, Or ETCF_OPTIMIZED_FOR_SPEED at the same time.  
Const ETCF_OPTIMIZED_FOR_SPEED   :Int = $8  ' Lets the driver decide in which format the textures are created And tries To Create them maximizing render speed. When using this flag, it does Not make sense To use the flags ETCF_ALWAYS_16_BIT, ETCF_ALWAYS_32_BIT, Or ETCF_OPTIMIZED_FOR_QUALITY, at the same time.  
Const ETCF_CREATE_MIP_MAPS       :Int = $10 ' Automatically creates mip map levels For the textures.  
Const ETCF_NO_ALPHA_CHANNEL      :Int = $20 ' Discard any alpha layer And use non-alpha color format.  
Const ETCF_ALLOW_NON_POWER_2     :Int = $40 ' Allow non power of two dimention textures

' A color format specifies how color information is stored
'Enum IRR_COLOR_FORMAT
Const ECF_A1R5G5B5:Int = 0    		' 16 bit color format used by the software driver, And thus preferred by all other irrlicht engine video drivers. There are 5 bits For every color component, And a single bit is Left For alpha information.  
Const ECF_R5G6B5:Int = 1			' Standard 16 bit color format.  
Const ECF_R8G8B8:Int = 2			' 24 bit color, no alpha channel, but 8 bit For red, green And blue.  
Const ECF_A8R8G8B8:Int = 3			' Default 32 bit color format. 8 bits are used For every component: red, green, blue And alpha.  

'Enum IRR_TEXTURE_BLEND
Const BLEND_SCREEN:Int = 0
Const BLEND_ADD:Int = 1
Const BLEND_SUBTRACT:Int = 2
Const BLEND_MULTIPLY:Int = 3
Const BLEND_DIVIDE:Int = 4

'Enum IRR_COLOR_MATERIAL
Const ECM_NONE:Int = 0            		' Dont use vertex color For lighting
Const ECM_DIFFUSE:Int = 1				' Use vertex color For diffuse light, (Default)
Const ECM_AMBIENT:Int = 2				' Use vertex color For ambient light
Const ECM_EMISSIVE:Int = 3				' Use vertex color For emissive light
Const ECM_SPECULAR:Int = 4				' Use vertex color For specular light
Const ECM_DIFFUSE_AND_AMBIENT:Int = 5	' Use vertex color For both diffuse And ambient light

'Enum IRR_DEBUG
Const EDS_OFF:Int = 0
Const EDS_BBOX:Int = 1
Const EDS_NORMALS:Int = 2
Const EDS_SKELETON:Int = 4
Const EDS_MESH_WIRE_OVERLAY:Int = 8
Const EDS_HALF_TRANSPARENCY:Int = 16
Const EDS_BBOX_BUFFERS:Int = 32
Const EDS_FULL:Int = $ffffffff

'Enum IRR_EGUI_EVENT_TYPE
    ' A gui element has lost its focus.
Const EGET_ELEMENT_FOCUS_LOST:Int = 0
    ' A gui element has got the focus.
Const EGET_ELEMENT_FOCUSED:Int = 1
    ' The mouse cursor hovered over a gui element.
Const EGET_ELEMENT_HOVERED:Int = 2
    ' The mouse cursor Left the hovered element.
Const EGET_ELEMENT_LEFT :Int = 3
    ' An element would like To close.
Const EGET_ELEMENT_CLOSED:Int = 4
    ' A button was clicked.
Const EGET_BUTTON_CLICKED:Int = 5
    ' A scrollbar has changed its position.
Const EGET_SCROLL_BAR_CHANGED:Int = 6
    ' A checkbox has changed its check state.
Const EGET_CHECKBOX_CHANGED:Int = 7
    ' A New item in a listbox was seleted.
Const EGET_LISTBOX_CHANGED:Int = 8
    ' An item in the listbox was selected, which was already selected.
Const EGET_LISTBOX_SELECTED_AGAIN:Int = 9
    ' A file has been selected in the file dialog
Const EGET_FILE_SELECTED:Int = 10
    ' A directory has been selected in the file dialog
Const EGET_DIRECTORY_SELECTED:Int = 11
    ' A file open dialog has been closed without choosing a file
Const EGET_FILE_CHOOSE_DIALOG_CANCELLED:Int = 12
    ' 'Yes' was clicked on a messagebox
Const EGET_MESSAGEBOX_YES:Int = 13
    ' 'No' was clicked on a messagebox
Const EGET_MESSAGEBOX_NO:Int = 14
    ' 'OK' was clicked on a messagebox
Const EGET_MESSAGEBOX_OK:Int = 15
    ' 'Cancel' was clicked on a messagebox
Const EGET_MESSAGEBOX_CANCEL:Int = 16
    ' In an editbox 'ENTER' was pressed
Const EGET_EDITBOX_ENTER:Int = 17
    ' The text in an editbox was changed. This does Not Include automatic changes in text-breaking.
Const EGET_EDITBOX_CHANGED:Int = 18
    ' The marked area in an editbox was changed.
Const EGET_EDITBOX_MARKING_CHANGED:Int = 19
    ' The tab was changed in an tab control
Const EGET_TAB_CHANGED:Int = 20
    ' A menu item was selected in a (context) menu
Const EGET_MENU_ITEM_SELECTED:Int = 21
    ' The selection in a combo box has been changed
Const EGET_COMBO_BOX_CHANGED:Int = 22
    ' The value of a spin box has changed
Const EGET_SPINBOX_CHANGED:Int = 23
    ' A table has changed
Const EGET_TABLE_CHANGED:Int = 24
Const EGET_TABLE_HEADER_CHANGED:Int = 25
Const EGET_TABLE_SELECTED_AGAIN:Int = 26
    ' A tree view node lost selection. See IGUITreeView::getLastEventNode().
Const EGET_TREEVIEW_NODE_DESELECT:Int = 27
    ' A tree view node was selected. See IGUITreeView::getLastEventNode().
Const EGET_TREEVIEW_NODE_SELECT:Int = 28
    ' A tree view node was expanded. See IGUITreeView::getLastEventNode().
Const EGET_TREEVIEW_NODE_EXPAND:Int = 29
    ' A tree view node was collapsed. See IGUITreeView::getLastEventNode().
Const EGET_TREEVIEW_NODE_COLLAPS:Int = 30
    ' No real event. Just For convenience To get number of events
Const EGET_COUNT:Int = 31

'Enum IRR_GUI_COLOR_ELEMENT
Const EGDC_3D_DARK_SHADOW:Int = 0     ' Dark shadow For three-dimensional display elements.  
Const EGDC_3D_SHADOW:Int = 1              ' Shadow color For three-dimensional display elements (For edges facing away from the light source).  
Const EGDC_3D_FACE:Int = 2                ' Face color For three-dimensional display elements And For dialog box backgrounds.  
Const EGDC_3D_HIGH_LIGHT:Int = 3          ' Highlight color For three-dimensional display elements (For edges facing the light source.).  
Const EGDC_3D_LIGHT:Int = 4               ' Light color For three-dimensional display elements (For edges facing the light source.).  
Const EGDC_ACTIVE_BORDER:Int = 5         ' Active window border.  
Const EGDC_ACTIVE_CAPTION:Int = 6        ' Active window title bar text.  
Const EGDC_APP_WORKSPACE:Int = 7         ' Background color of multiple document interface (MDI) applications.  
Const EGDC_BUTTON_TEXT:Int = 8          ' Text on a button.  
Const EGDC_GRAY_TEXT:Int = 9            ' Grayed (disabled) text.  
Const EGDC_HIGH_LIGHT:Int = 10           ' Item(s) selected in a control.  
Const EGDC_HIGH_LIGHT_TEXT:Int = 11       ' Text of item(s) selected in a control.  
Const EGDC_INACTIVE_BORDER:Int = 12       ' Inactive window border.  
Const EGDC_INACTIVE_CAPTION:Int = 13      ' Inactive window caption.  
Const EGDC_TOOLTIP:Int = 14               ' Tool tip text color.  
Const EGDC_TOOLTIP_BACKGROUND:Int = 15    ' Tool tip background color.  
Const EGDC_SCROLLBAR:Int = 16             ' Scrollbar gray area.  
Const EGDC_WINDOW:Int = 17                ' Window background.  
Const EGDC_WINDOW_SYMBOL:Int = 18         ' Window symbols like on close buttons, scroll bars And check boxes.  
Const EGDC_ICON:Int = 19                  ' Icons in a list Or tree.  
Const EGDC_ICON_HIGH_LIGHT:Int = 20       ' Selected icons in a list Or tree.  
Const EGDC_COUNT:Int = 21                 ' this value is Not used, it only specifies the amount of Default colors available.  

'' ////////////////////////////////////////////////////////////////////////////
'' Constant Definitions

' No value, usually used when you do Not wish To pass an Object To a call
Const IRR_NO_OBJECT:Int = Null

' Parenting of nodes
Const IRR_NO_PARENT:Int = Null

' Flag definition
Const IRR_OFF:Int = 0
Const IRR_ON:Int = 1

' Input definitions
Const IRR_KEY_UP:Int = 0
Const IRR_KEY_DOWN:Int = 1

' The number of bits per pixel in the display
Const IRR_BITS_PER_PIXEL_16:Int = 16
Const IRR_BITS_PER_PIXEL_32:Int = 32

' System Device definitions
Const IRR_WINDOWED:Int = 0
Const IRR_FULLSCREEN:Int = 1

Const IRR_NO_SHADOWS:Int = 0
Const IRR_SHADOWS:Int = 1

Const IRR_IGNORE_EVENTS:Int = 0
Const IRR_CAPTURE_EVENTS:Int = 1

Const IRR_LINEAR_FOG:Int = 0
Const IRR_EXPONENTIAL_FOG:Int = 1

Const IRR_VERTICAL_SYNC_OFF:Int = 0
Const IRR_VERTICAL_SYNC_ON:Int = 1

' Filing system definitions
Const IRR_USE_CASE:Int = 0
Const IRR_IGNORE_CASE:Int = 1
Const IRR_USE_PATHS:Int = 0
Const IRR_IGNORE_PATHS:Int = 1

' 2D image definitions
Const IRR_IGNORE_ALPHA:Int = 0
Const IRR_USE_ALPHA:Int = 1

' Node definitions
Const IRR_INVISIBLE:Int = 0
Const IRR_VISIBLE:Int = 1

Const IRR_ONE_SHOT:Int = 0
Const IRR_LOOP:Int = 1

' Particle definitions
Const IRR_NO_EMITTER:Int = 0
Const IRR_DEFAULT_EMITTER:Int = 1

Const IRR_ATTRACT:Int = 1
Const IRR_REPEL:Int = 0

' GUI Interface definitions
Const IRR_GUI_NO_BORDER:Int = 0
Const IRR_GUI_BORDER:Int = 1
Const IRR_GUI_NO_WRAP:Int = 0
Const IRR_GUI_WRAP:Int = 1
Const IRR_GUI_HORIZONTAL:Int = 1
Const IRR_GUI_VERTICAL:Int = 0
Const IRR_GUI_MODAL:Int = 1
Const IRR_GUI_NOT_MODAL:Int = 0
Const IRR_GUI_DRAW_BACKGROUND:Int = 1
Const IRR_GUI_EMPTY_BACKGROUND:Int = 0
Const IRR_GUI_PASSWORD:Int = 1
Const IRR_GUI_NOT_PASSWORD:Int = 0

' Spherical Terrain Faces
Const IRR_TOP_FACE:Int = 0
Const IRR_FRONT_FACE:Int = 1
Const IRR_BACK_FACE:Int = 2
Const IRR_LEFT_FACE:Int = 3
Const IRR_RIGHT_FACE:Int = 4
Const IRR_BOTTOM_FACE:Int = 5

' attach a tile onto this tile
Const TOP_EDGE:Int = 0
Const BOTTOM_EDGE:Int = 1
Const LEFT_EDGE:Int = 2
Const RIGHT_EDGE:Int = 3


'' ////////////////////////////////////////////////////////////////////////////
'' Type Definitions

' Irrlicht Keyboard and Mouse Event Structures
Type IRR_MOUSE_EVENT
    Field action:Int
    Field delta:Float
    Field x:Int
    Field y:Int
End Type

Type IRR_KEY_EVENT
    Field key:Int
    Field direction:Int
    Field flags:Int
End Type

Type IRR_GUI_EVENT
    Field id:Int
    Field event:Int'IRR_EGUI_EVENT_TYPE
    Field x:Int
    Field y:Int
End Type

' Particle emitter properties
Type IRR_PARTICLE_EMITTER
    Field min_box_x:Float	    			 ' The bounding box for the emitter
    Field min_box_y:Float
    Field min_box_z:Float

    Field max_box_x:Float
    Field max_box_y:Float
    Field max_box_z:Float

    Field direction_x:Float
    Field direction_y:Float
    Field direction_z:Float

    Field min_paritlcles_per_second:Int
    Field max_paritlcles_per_second:Int

    Field min_start_color_red:Int
    Field min_start_color_green:Int
    Field min_start_color_blue:Int

    Field max_start_color_red:Int
    Field max_start_color_green:Int
    Field max_start_color_blue:Int
    
    Field min_lifetime:Int
    Field max_lifetime:Int
    
    Field min_start_sizeX:Float
    Field min_start_sizeY:Float
    
    Field max_start_sizeX:Float
    Field max_start_sizeY:Float
    
    Field max_angle_degrees:Int
End Type

' a vertex used in creating custom static mesh objects
Type IRR_VERT
    Field x:Float             ' The x position of the vertex
    Field y:Float             ' The y position of the vertex
    Field z:Float             ' The z position of the vertex
    Field normal_x:Float      ' The x normal of the vertex
    Field normal_y:Float      ' The y normal of the vertex
    Field normal_z:Float      ' The z normal of the vertex
    Field vcolor:Int      ' The 32bit ARGB color of the vertex
    Field texture_x:Float     ' the x co-ordinate of the vertex on the texture (0 to 1)
    Field texture_y:Float     ' the y co-ordinate of the vertex on the texture (0 to 1)
End Type

' a vector consisting of 3 float values
Type IRR_VECTOR
    Field x:Float
    Field y:Float
    Field z:Float
End Type

' a size consisting of 2 float values
Type IRR_SIZE
    Field x:Float
    Field y:Float
End Type

' the contents of a key event
Type SKeyMap
    Field Action:Int'EKEY_ACTION
    Field KeyCode:Int'EKEY_CODE
End Type

' a material representing a new shader
Type IRR_SHADER
    ' use the material type in a call to IrrSetNodeMaterialType
    Field material_type:Int
    ' the following properties are reserved for internal use changing them can
    ' result in crashes and memory leakage
    Field material_object:Int Ptr
    Field next_shader:Int Ptr
End Type

Type SBillboard
    Field Position:IRR_VECTOR
    Field Size:IRR_SIZE
    Field Roll:Float
    Field Axis:IRR_VECTOR
    Field HasAxis:Int
    Field sColor:Int
    
    Field vertexIndex:Int
    Field sprev:Int Ptr
    Field snext:Int Ptr
End Type


' .............................................................................
' Irrlicht Object Types - these are used to represent objects in the Irrlicht
' engine and their purpose is to warn the programmer of type errors
' (thanks to v1ctor for the advice on this correction)
Global irr_mesh:Int Ptr

Global irr_image:Int Ptr

Global irr_texture:Int Ptr

Global irr_material:Int Ptr

Global irr_node:Int Ptr

Global irr_camera:Int Ptr

Global irr_terrain:Int Ptr

Global irr_selector:Int Ptr

Global irr_particle_system:Int Ptr

Global irr_emitter:Int Ptr

Global irr_affector:Int Ptr

Global irr_animator:Int Ptr

Global irr_font:Int Ptr

Global irr_scene_node:Int Ptr

Global irr_gui_object:Int Ptr

Type irr_model
    Field node:Int Ptr
    Field camera:Int Ptr
    Field terrain:Int Ptr
    Field particles:Int Ptr
End Type




'Enum EKEY_CODE
Const KEY_LBUTTON         :Int = $01  ' Left mouse button  
Const KEY_RBUTTON         :Int = $02  ' Right mouse button  
Const KEY_CANCEL          :Int = $03  ' Control-break processing  
Const KEY_MBUTTON         :Int = $04  ' Middle mouse button (three-button mouse)  
Const KEY_XBUTTON1        :Int = $05  ' Windows 2000/XP: X1 mouse button 
Const KEY_XBUTTON2        :Int = $06  ' Windows 2000/XP: X2 mouse button 
Const KEY_BACK            :Int = $08  ' BACKSPACE key  
Const KEY_TAB             :Int = $09  ' Tab key  
Const KEY_CLEAR           :Int = $0C  ' Clear key  
'Const KEY_RETURN          :Int = $0D  ' ENTER key  
Const KEY_SHIFT           :Int = $10  ' SHIFT key  
Const KEY_CONTROL         :Int = $11  ' CTRL key  
Const KEY_MENU            :Int = $12  ' ALT key  
Const KEY_PAUSE           :Int = $13  ' PAUSE key  
Const KEY_CAPITAL         :Int = $14  ' CAPS Lock key  
Const KEY_KANA            :Int = $15  ' IME Kana mode 
Const KEY_HANGUEL         :Int = $15  ' IME Hanguel mode (maintained For compatibility use KEY_HANGUL) 
Const KEY_HANGUL          :Int = $15  ' IME Hangul mode 
Const KEY_JUNJA           :Int = $17  ' IME Junja mode 
Const KEY_FINAL           :Int = $18  ' IME final mode 
Const KEY_HANJA           :Int = $19  ' IME Hanja mode 
Const KEY_KANJI           :Int = $19  ' IME Kanji mode 
'Const KEY_ESCAPE          :Int = $1B  ' ESC key  
Const KEY_CONVERT         :Int = $1C  ' IME convert 
Const KEY_NONCONVERT      :Int = $1D  ' IME nonconvert 
Const KEY_ACCEPT          :Int = $1E  ' IME accept 
Const KEY_MODECHANGE      :Int = $1F  ' IME mode change request 
'Const KEY_SPACE           :Int = $20  ' SPACEBAR  
Const KEY_PRIOR           :Int = $21  ' PAGE UP key  
Const KEY_NEXT            :Int = $22  ' PAGE DOWN key  
Const KEY_END             :Int = $23  ' End key  
Const KEY_HOME            :Int = $24  ' HOME key  
Const KEY_LEFT            :Int = $25  ' Left ARROW key  
Const KEY_UP              :Int = $26  ' UP ARROW key  
Const KEY_RIGHT           :Int = $27  ' Right ARROW key  
Const KEY_DOWN            :Int = $28  ' DOWN ARROW key  
Const KEY_SELECT          :Int = $29  ' Select key  
Const KEY_PRINT           :Int = $2A  ' Print key
Const KEY_EXECUT          :Int = $2B  ' EXECUTE key  
Const KEY_SNAPSHOT        :Int = $2C  ' Print Screen key  
Const KEY_INSERT          :Int = $2D  ' INS key  
Const KEY_DELETE          :Int = $2E  ' DEL key  
Const KEY_HELP            :Int = $2F  ' HELP key  
Const KEY_KEY_0           :Int = $30  ' 0 key  
Const KEY_KEY_1           :Int = $31  ' 1 key  
Const KEY_KEY_2           :Int = $32  ' 2 key  
Const KEY_KEY_3           :Int = $33  ' 3 key  
Const KEY_KEY_4           :Int = $34  ' 4 key  
Const KEY_KEY_5           :Int = $35  ' 5 key  
Const KEY_KEY_6           :Int = $36  ' 6 key  
Const KEY_KEY_7           :Int = $37  ' 7 key  
Const KEY_KEY_8           :Int = $38  ' 8 key  
Const KEY_KEY_9           :Int = $39  ' 9 key  
Const KEY_KEY_A           :Int = $41  ' A key  
Const KEY_KEY_B           :Int = $42  ' B key  
Const KEY_KEY_C           :Int = $43  ' C key  
Const KEY_KEY_D           :Int = $44  ' D key  
Const KEY_KEY_E           :Int = $45  ' E key  
Const KEY_KEY_F           :Int = $46  ' F key  
Const KEY_KEY_G           :Int = $47  ' G key  
Const KEY_KEY_H           :Int = $48  ' H key  
Const KEY_KEY_I           :Int = $49  ' I key  
Const KEY_KEY_J           :Int = $4A  ' J key  
Const KEY_KEY_K           :Int = $4B  ' K key  
Const KEY_KEY_L           :Int = $4C  ' L key  
Const KEY_KEY_M           :Int = $4D  ' M key  
Const KEY_KEY_N           :Int = $4E  ' N key  
Const KEY_KEY_O           :Int = $4F  ' O key  
Const KEY_KEY_P           :Int = $50  ' P key  
Const KEY_KEY_Q           :Int = $51  ' Q key  
Const KEY_KEY_R           :Int = $52  ' R key  
Const KEY_KEY_S           :Int = $53  ' S key  
Const KEY_KEY_T           :Int = $54  ' T key  
Const KEY_KEY_U           :Int = $55  ' U key  
Const KEY_KEY_V           :Int = $56  ' V key  
Const KEY_KEY_W           :Int = $57  ' W key  
Const KEY_KEY_X           :Int = $58  ' X key  
Const KEY_KEY_Y           :Int = $59  ' Y key  
Const KEY_KEY_Z           :Int = $5A  ' Z key  
Const KEY_LWIN            :Int = $5B  ' Left Windows key (Microsoft® Natural® keyboard)  
Const KEY_RWIN            :Int = $5C  ' Right Windows key (Natural keyboard)  
Const KEY_APPS            :Int = $5D  ' Applications key (Natural keyboard)  
Const KEY_SLEEP           :Int = $5F  ' Computer Sleep key 
Const KEY_NUMPAD0         :Int = $60  ' Numeric keypad 0 key  
Const KEY_NUMPAD1         :Int = $61  ' Numeric keypad 1 key  
Const KEY_NUMPAD2         :Int = $62  ' Numeric keypad 2 key  
Const KEY_NUMPAD3         :Int = $63  ' Numeric keypad 3 key  
Const KEY_NUMPAD4         :Int = $64  ' Numeric keypad 4 key  
Const KEY_NUMPAD5         :Int = $65  ' Numeric keypad 5 key  
Const KEY_NUMPAD6         :Int = $66  ' Numeric keypad 6 key  
Const KEY_NUMPAD7         :Int = $67  ' Numeric keypad 7 key  
Const KEY_NUMPAD8         :Int = $68  ' Numeric keypad 8 key  
Const KEY_NUMPAD9         :Int = $69  ' Numeric keypad 9 key  
Const KEY_MULTIPLY        :Int = $6A  ' Multiply key  
Const KEY_ADD             :Int = $6B  ' Add key  
Const KEY_SEPARATOR       :Int = $6C  ' Separator key  
Const KEY_SUBTRACT        :Int = $6D  ' Subtract key  
Const KEY_DECIMAL         :Int = $6E  ' Decimal key  
Const KEY_DIVIDE          :Int = $6F  ' Divide key  
Const KEY_F1              :Int = $70  ' F1 key  
Const KEY_F2              :Int = $71  ' F2 key  
Const KEY_F3              :Int = $72  ' F3 key  
Const KEY_F4              :Int = $73  ' F4 key  
Const KEY_F5              :Int = $74  ' F5 key  
Const KEY_F6              :Int = $75  ' F6 key  
Const KEY_F7              :Int = $76  ' F7 key  
Const KEY_F8              :Int = $77  ' F8 key  
Const KEY_F9              :Int = $78  ' F9 key  
Const KEY_F10             :Int = $79  ' F10 key  
Const KEY_F11             :Int = $7A  ' F11 key  
Const KEY_F12             :Int = $7B  ' F12 key  
Const KEY_F13             :Int = $7C  ' F13 key  
Const KEY_F14             :Int = $7D  ' F14 key  
Const KEY_F15             :Int = $7E  ' F15 key  
Const KEY_F16             :Int = $7F  ' F16 key  
Const KEY_F17             :Int = $80  ' F17 key  
Const KEY_F18             :Int = $81  ' F18 key  
Const KEY_F19             :Int = $82  ' F19 key  
Const KEY_F20             :Int = $83  ' F20 key  
Const KEY_F21             :Int = $84  ' F21 key  
Const KEY_F22             :Int = $85  ' F22 key  
Const KEY_F23             :Int = $86  ' F23 key  
Const KEY_F24             :Int = $87  ' F24 key  
Const KEY_NUMLOCK         :Int = $90  ' NUM Lock key  
Const KEY_SCROLL          :Int = $91  ' SCROLL Lock key  
Const KEY_LSHIFT          :Int = $A0  ' Left SHIFT key 
Const KEY_RSHIFT          :Int = $A1  ' Right SHIFT key 
Const KEY_LCONTROL        :Int = $A2  ' Left CONTROL key 
Const KEY_RCONTROL        :Int = $A3  ' Right CONTROL key 
Const KEY_LMENU           :Int = $A4  ' Left MENU key 
Const KEY_RMENU           :Int = $A5  ' Right MENU key 
Const KEY_PLUS            :Int = $BB  ' Plus Key   (+)
'Const KEY_COMMA           :Int = $BC  ' Comma Key  (,)
Const KEY_MINUS           :Int = $BD  ' Minus Key  (-)
'Const KEY_PERIOD          :Int = $BE  ' Period Key (.)
Const KEY_ATTN            :Int = $F6  ' Attn key 
Const KEY_CRSEL           :Int = $F7  ' CrSel key 
Const KEY_EXSEL           :Int = $F8  ' ExSel key 
Const KEY_EREOF           :Int = $F9  ' Erase Eof key 
Const KEY_PLAY            :Int = $FA  ' Play key 
Const KEY_ZOOM            :Int = $FB  ' Zoom key 
Const KEY_PA1             :Int = $FD  ' PA1 key 
Const KEY_OEM_CLEAR       :Int = $FE  ' Clear key 
Const KEY_KEY_CODES_COUNT :Int = $FF  ' this Is Not a key but the amount of keycodes there are.
'End Enum


'' ----------------------------------------------------------------------------
'' 					IRRKLANG CONSTANTS
'' ----------------------------------------------------------------------------

'E_SOUND_OUTPUT_DRIVER
Const ESOD_AUTO_DETECT:Int 			= 0			' Auto detects the best sound driver for the system
Const ESOD_DIRECT_SOUND:Int 		= 1			' DirectSound sound output driver, windows only
Const ESOD_NULL:Int 				= 2			' Null driver, creating no sound output
Const ESOD_COUNT:Int 				= 3			' Amount of built-in sound engine types
Const ESOD_FORCE_32_BIT:Int	 		= $7fffffff

'E_SOUND_ENGINE_OPTIONS
Const ESEO_MULTI_THREADED:Int 					= 1
Const ESEO_MUTE_IF_NOT_FOCUSED:Int 				= 2
Const ESEO_LOAD_PLUGINS:Int 					= 4
Const ESEO_USE_3D_BUFFERS:Int 					= 8
Const ESEO_PRINT_DEBUG_INFO_TO_DEBUGGER:Int		= 16
Const ESEO_LINEAR_ROLLOFF:Int 					= 32
Const ESEO_DEFAULT_OPTIONS:Int 					= 29
Const ESEO_FORCE_32_BIT:Int 					= $7fffffff

'E_STREAM_MODE
Const ESM_AUTO_DETECT:Int 				= 0
Const ESM_STREAMING:Int 				= 1
Const ESM_NO_STREAMING:Int 				= 2
Const ESM_FORCE_32_BIT:Int 				= $7fffffff


'Extern
'' ////////////////////////////////////////////////////////////////////////////
'' System Functions

''	Global

Rem
	bbdoc:	iIrr3D%(width%,height%,bpp%,fullscreen%)
	about:	Start the Irrlicht Engine.
	returns:	1 for success, 0 for fail.
EndRem
Global iIrr3D%(width%,height%,bpp%,fullscreen%)"Win32" = GetProcAddress(DllHandle,"iIrr3D")
Rem
	bbdoc:	iIrr3DAdvanced%(drivertype%,scrWidth%,scrHeight%,bits%,fullscreen%,shadows%,dontignoreinput%,vsyncenabled%,devicetype%,doublebufferenabled%,antialiasenabled%,highprecisionfpu%)
	about:	Start the Irrlicht Engine.
	returns:	1 for success, 0 for fail.
EndRem
Global iIrr3DAdvanced%(drivertype%,scrWidth%,scrHeight%,bits%,fullscreen%,shadows%,dontignoreinput%,vsyncenabled%,devicetype%,doublebufferenabled%,antialiasenabled%,highprecisionfpu%)"Win32" = GetProcAddress(DllHandle,"iIrr3DAdvanced")
Rem
	bbdoc:	iUseDirect3D9()
	about:	Use prior to starting Irrlicht, use DirectX9 driver.
	returns:	None.
EndRem
Global iUseDirect3D9()"Win32" = GetProcAddress(DllHandle,"iUseDirect3D9")
Rem
bbdoc: iVSync(apply%)
returns: True (Default) vsync is enabled.
End Rem
Global iVSync(apply%)"Win32" = GetProcAddress(DllHandle,"iVSync")
Rem
bbdoc:
returns:
End Rem
Global iUseOpenGL()"Win32" = GetProcAddress(DllHandle,"iUseOpenGL")
Rem
bbdoc:
returns:
End Rem
Global iUseSoftware()"Win32" = GetProcAddress(DllHandle,"iUseSoftware")
Rem
bbdoc:
returns:
End Rem
Global iEndIrr3D()"Win32" = GetProcAddress(DllHandle,"iEndIrr3D")
Rem
bbdoc:
returns:
End Rem
Global iRun%()"Win32" = GetProcAddress(DllHandle,"iRun")
Rem
bbdoc:
returns:
End Rem
Global iBeginScene()"Win32" = GetProcAddress(DllHandle,"iBeginScene")
Rem
bbdoc:
returns:
End Rem
Global iBeginSceneAdvanced(sceneBackgroundColor%,clearBackBuffer%,clearZBuffer%)"Win32" = GetProcAddress(DllHandle,"iBeginSceneAdvanced")
Rem
bbdoc:
returns:
End Rem
Global iCameraCLSColor(r%,g%,b%)"Win32" = GetProcAddress(DllHandle,"iCameraCLSColor")
Rem
bbdoc:
returns:
End Rem
Global iDrawScene()"Win32" = GetProcAddress(DllHandle,"iDrawScene")
Rem
bbdoc:
returns:
End Rem
Global iEndScene()"Win32" = GetProcAddress(DllHandle,"iEndScene")
Rem
bbdoc:
returns:
End Rem
Global iTrisDrawn%()"Win32" = GetProcAddress(DllHandle,"iTrisDrawn")
Rem
bbdoc:
returns:
End Rem
Global iQueryFeature%(feature%)"Win32" = GetProcAddress(DllHandle,"iQueryFeature")
Rem
bbdoc:
returns:
End Rem
Global iDisableFeature(feature%,state%)"Win32" = GetProcAddress(DllHandle,"iDisableFeature")
Rem
bbdoc:
returns:
End Rem
Global iGetFPS%()"Win32" = GetProcAddress(DllHandle,"iGetFPS")
Rem
bbdoc:
returns:
End Rem
Global iAppTitle(title$Z)"Win32" = GetProcAddress(DllHandle,"iAppTitle")
Rem
bbdoc:
returns:
End Rem
Global iDrawGUI()"Win32" = GetProcAddress(DllHandle,"iDrawGUI")
Rem
bbdoc:
returns:
End Rem
Global iTime%()"Win32" = GetProcAddress(DllHandle,"iTime")
Rem
bbdoc:
returns:
End Rem
Global iGraphicsWidth%()"Win32" = GetProcAddress(DllHandle,"iGraphicsWidth")
Rem
bbdoc:
returns:
End Rem
Global iGraphicsHeight%()"Win32" = GetProcAddress(DllHandle,"iGraphicsHeight")
Rem
bbdoc:
returns:
End Rem
Global iViewPort(x%,y%,width%,height%)"Win32" = GetProcAddress(DllHandle,"iViewPort")
Rem
bbdoc:
returns:
End Rem
Global iClearScene()"Win32" = GetProcAddress(DllHandle,"iClearScene")
Rem
bbdoc:
returns:
End Rem
Global iAmbientLight(r#,g#,b#)"Win32" = GetProcAddress(DllHandle,"iAmbientLight")
Rem
bbdoc:
returns:
End Rem
Global iShadowColor(alpha%,r%,g%,b%)"Win32" = GetProcAddress(DllHandle,"iShadowColor")
Rem
bbdoc:
returns:
End Rem
Global iCameraFog(r%,g%,b%,FogType%,near#,far#,density#)"Win32" = GetProcAddress(DllHandle,"iCameraFog")
Rem
bbdoc:
returns:
End Rem
Global iDraw3DLine(xStart#,yStart#,zStart#,xEnd#,yEnd#,zEnd#,R%,G%,B%)"Win32" = GetProcAddress(DllHandle,"iDraw3DLine")
Rem
bbdoc:
returns:
End Rem
Global iReadPixelFast%(x%,y%,image%)"Win32" = GetProcAddress(DllHandle,"iReadPixelFast")
Rem
bbdoc:
returns:
End Rem
Global iWritePixelFast(x%,y%,image%)"Win32" = GetProcAddress(DllHandle,"iWritePixelFast")
Rem
bbdoc:
returns:
End Rem
Global iLoadScene(filename$z)"Win32" = GetProcAddress(DllHandle,"iLoadScene")
Rem
bbdoc:
returns:
End Rem
Global iSaveScene(filename$)"Win32" = GetProcAddress(DllHandle,"iSaveScene")
Rem
bbdoc:
returns:
End Rem
Global iTransparentZWrite(on%)"Win32" = GetProcAddress(DllHandle,"iTransparentZWrite")


''  FONT And TEXT

Rem
bbdoc:
returns:
End Rem
Global iLoadFont%(path$z)"Win32" = GetProcAddress(DllHandle,"iLoadFont")
Rem
bbdoc:
returns:
End Rem
Global iText(font%,Text$z,top_x%,top_y%,bottom_x%,bottom_y%)"Win32" = GetProcAddress(DllHandle,"iText")
Rem
bbdoc:
returns:
End Rem
Global iColor(alpha%,red%,green%,blue%)"Win32" = GetProcAddress(DllHandle,"iColor")


''  EVENTS KEYBOARD \ MOUSE \ GUI

Rem
bbdoc:
returns:
End Rem
Global iKeyHit%(key%)"Win32" = GetProcAddress(DllHandle,"iKeyHit")
Rem
bbdoc:
returns:
End Rem
Global iKeyDown%(key%)"Win32" = GetProcAddress(DllHandle,"iKeyDown")
Rem
bbdoc:
returns:
End Rem
Global iFlushKeys()"Win32" = GetProcAddress(DllHandle,"iFlushKeys")
Rem
bbdoc:
returns:
End Rem
Global iMouseDown%(button%)"Win32" = GetProcAddress(DllHandle,"iMouseDown")
Rem
bbdoc:
returns:
End Rem
Global iMouseWheel#()"Win32" = GetProcAddress(DllHandle,"iMouseWheel")
Rem
bbdoc:
returns:
End Rem
Global iFlushMouse()"Win32" = GetProcAddress(DllHandle,"iFlushMouse")
Rem
bbdoc:
returns:
End Rem
Global iGUIEventAvailable%()"Win32" = GetProcAddress(DllHandle,"iGUIEventAvailable")
Rem
bbdoc:
returns:
End Rem
Global iReadGUIEvent()"Win32" = GetProcAddress(DllHandle,"iReadGUIEvent")
Rem
bbdoc:
returns:
End Rem
Global iGUIEventID%()"Win32" = GetProcAddress(DllHandle,"iGUIEventID")
Rem
bbdoc:
returns:
End Rem
Global iGUIEvent%()"Win32" = GetProcAddress(DllHandle,"iGUIEvent")
Rem
bbdoc:
returns:
End Rem
Global iGUIEventData%()"Win32" = GetProcAddress(DllHandle,"iGUIEventData")
Rem
bbdoc:
returns:
End Rem
Global iShowMouse()"Win32" = GetProcAddress(DllHandle,"iShowMouse")
Rem
bbdoc:
returns:
End Rem
Global iHideMouse()"Win32" = GetProcAddress(DllHandle,"iHideMouse")
Rem
bbdoc:
returns:
End Rem
Global iMoveMouse(x#,y#)"Win32" = GetProcAddress(DllHandle,"iMoveMouse")
Rem
bbdoc:
returns:
End Rem
Global iMouseX%()"Win32" = GetProcAddress(DllHandle,"iMouseX")
Rem
bbdoc:
returns:
End Rem
Global iMouseY%()"Win32" = GetProcAddress(DllHandle,"iMouseY")
Rem
bbdoc:
returns:
End Rem
Global iGetKey%()"Win32" = GetProcAddress(DllHandle,"iGetKey")
Rem
bbdoc:
returns:
End Rem
Global iWaitKey()"Win32" = GetProcAddress(DllHandle,"iWaitKey")
Rem
bbdoc:
returns:
End Rem
Global iGetLastSelectedFile$z()"Win32" = GetProcAddress(DllHandle,"iGetLastSelectedFile")


''  NODE MOVEMENT

Rem
bbdoc:
returns:
End Rem
Global iScaleNode(node%,x#,y#,z#)"Win32" = GetProcAddress(DllHandle,"iScaleNode")
Rem
bbdoc:
returns:
End Rem
Global iPositionNode(node%,X#,Y#,Z#)"Win32" = GetProcAddress(DllHandle,"iPositionNode")
Rem
bbdoc:
returns:
End Rem
Global iRotateNode(node%,x#,y#,z#)"Win32" = GetProcAddress(DllHandle,"iRotateNode")
Rem
bbdoc:
returns:
End Rem
Global iTurnNode(node%,pitch#,yaw#,roll#)"Win32" = GetProcAddress(DllHandle,"iTurnNode")
Rem
bbdoc:
returns:
End Rem
Global iMoveNode(node%,x#,y#,z#)"Win32" = GetProcAddress(DllHandle,"iMoveNode")


''  NODE SPECIAL

Rem
bbdoc:
returns:
End Rem
Global iCreateWater%(mesh%,waveHeight#,waveSpeed#,waveLength#,parent%,id%,positionX#,positionY#,positionZ#,rotationX#,rotationY#,rotationZ#,scaleX#,scaleY#,scaleZ#)"Win32" = GetProcAddress(DllHandle,"iCreateWater")
Rem
bbdoc:
returns:
End Rem
Global iCreateClouds%(texture%,lod%,depth%,density%)"Win32" = GetProcAddress(DllHandle,"iCreateClouds")
Rem
bbdoc:
returns:
End Rem
Global iCreateFlare%(texture%)"Win32" = GetProcAddress(DllHandle,"iCreateFlare")
Rem
bbdoc:
returns:
End Rem
Global iFlareScale(flare%,source#,optics#)"Win32" = GetProcAddress(DllHandle,"iFlareScale")
Rem
bbdoc:
returns:
End Rem
Global iCreateGrass%(terrain%,x%,y%,patchSize%,fadeDistance#,crossed%,grassScale#,maxDensity%,dataPositionX%,dataPositionY%,heightMap%,textureMap%,grassMap%,grassTexture%)"Win32" = GetProcAddress(DllHandle,"iCreateGrass")
Rem
bbdoc:
returns:
End Rem
Global iGrassDensity(grass%,density%,distance#)"Win32" = GetProcAddress(DllHandle,"iGrassDensity")
Rem
bbdoc:
returns:
End Rem
Global iGrassWind(grass%,strength#,resolution#)"Win32" = GetProcAddress(DllHandle,"iGrassWind")
Rem
bbdoc:
returns:
End Rem
Global iGrassDrawCount%(grass%)"Win32" = GetProcAddress(DllHandle,"iGrassDrawCount")
Rem
bbdoc:
returns:
End Rem
Global iCreateBolt%()"Win32" = GetProcAddress(DllHandle,"iCreateBolt")
Rem
bbdoc:
returns:
End Rem
Global iBoltProperties(bolt%,sx#,sy#,sz#,ex#,ey#,ez#,updateTime%,height%,thickness#,parts%,bolts%,steadyend%,r%,g%,b%,alpha%)"Win32" = GetProcAddress(DllHandle,"iBoltProperties")
Rem
bbdoc:
returns:
End Rem
Global iCreateBeam%()"Win32" = GetProcAddress(DllHandle,"iCreateBeam")
Rem
bbdoc:
returns:
End Rem
Global iBeamSize(beam%,size#)"Win32" = GetProcAddress(DllHandle,"iBeamSize")
Rem
bbdoc:
returns:
End Rem
Global iPositionBeam(beam%,sx#,sy#,sz#,ex#,ey#,ez#)"Win32" = GetProcAddress(DllHandle,"iPositionBeam")
Rem
bbdoc:
returns:
End Rem
Global iCreatePivot%()"Win32" = GetProcAddress(DllHandle,"iCreatePivot")
Rem
bbdoc:
returns:
End Rem
Global iCreateSkybox%(up_texture%,down_texture%,left_texture%,right_texture%,front_texture%,back_texture%)"Win32" = GetProcAddress(DllHandle,"iCreateSkybox")


''  NODE STATE

Rem
bbdoc:
returns:
End Rem
Global iNodeX#(node%,bGlobal%)"Win32" = GetProcAddress(DllHandle,"iNodeX")
Rem
bbdoc:
returns:
End Rem
Global iNodeY#(node%,bGlobal%)"Win32" = GetProcAddress(DllHandle,"iNodeY")
Rem
bbdoc:
returns:
End Rem
Global iNodeZ#(node%,bGlobal%)"Win32" = GetProcAddress(DllHandle,"iNodeZ")
Rem
bbdoc:
returns:
End Rem
Global iNodeRoll#(node%,bGlobal%)"Win32" = GetProcAddress(DllHandle,"iNodeRoll")
Rem
bbdoc:
returns:
End Rem
Global iNodeYaw#(node%,bGlobal%)"Win32" = GetProcAddress(DllHandle,"iNodeYaw")
Rem
bbdoc:
returns:
End Rem
Global iNodePitch#(node%,bGlobal%)"Win32" = GetProcAddress(DllHandle,"iNodePitch")
Rem
bbdoc:
returns:
End Rem
Global iLinePick%(x#,y#,z#,dx#,dy#,dz#)"Win32" = GetProcAddress(DllHandle,"iLinePick")
Rem
bbdoc:
returns:
End Rem
Global iCameraPick%(camera%,x%,y%)"Win32" = GetProcAddress(DllHandle,"iCameraPick")
Rem
bbdoc:
returns:
End Rem
Global iPickedX#()"Win32" = GetProcAddress(DllHandle,"iPickedX")
Rem
bbdoc:
returns:
End Rem
Global iPickedY#()"Win32" = GetProcAddress(DllHandle,"iPickedY")
Rem
bbdoc:
returns:
End Rem
Global iPickedZ#()"Win32" = GetProcAddress(DllHandle,"iPickedZ")
Rem
bbdoc:
returns:
End Rem
Global iPickedNX#()"Win32" = GetProcAddress(DllHandle,"iPickedNX")
Rem
bbdoc:
returns:
End Rem
Global iPickedNY#()"Win32" = GetProcAddress(DllHandle,"iPickedNY")
Rem
bbdoc:
returns:
End Rem
Global iPickedNZ#()"Win32" = GetProcAddress(DllHandle,"iPickedNZ")
Rem
bbdoc:
returns:
End Rem
Global iNodeClass%(node%)"Win32" = GetProcAddress(DllHandle,"iNodeClass")
Rem
bbdoc:
returns:
End Rem
Global iNodeName$z(node%)"Win32" = GetProcAddress(DllHandle,"iNodeName")
Rem
bbdoc:
returns:
End Rem
Global iNodeID%(node%)"Win32" = GetProcAddress(DllHandle,"iNodeID")
Rem
bbdoc:
returns:
End Rem
Global iCountChildren%(node%)"Win32" = GetProcAddress(DllHandle,"iCountChildren")
Rem
bbdoc:
returns:
End Rem
Global iGetChild%(node%,index%)"Win32" = GetProcAddress(DllHandle,"iGetChild")
Rem
bbdoc:
returns:
End Rem
Global iNodeShadow(node%)"Win32" = GetProcAddress(DllHandle,"iNodeShadow")
Rem
bbdoc:
returns:
End Rem
Global iRemoveNodeShadow%(node%,shadow%)"Win32" = GetProcAddress(DllHandle,"iRemoveNodeShadow")
Rem
bbdoc:
returns:
End Rem
Global iNodeDistance#(src_node%,dest_node%)"Win32" = GetProcAddress(DllHandle,"iNodeDistance")
Rem
bbdoc:
returns:
End Rem
Global iDebugNode(node%,state%)"Win32" = GetProcAddress(DllHandle,"iDebugNode")
Rem
bbdoc:
returns:
End Rem
Global iNodeMaterialFlag(node%,flag%,value%)"Win32" = GetProcAddress(DllHandle,"iNodeMaterialFlag")
Rem
bbdoc:
returns:
End Rem
Global iNodeMaterialType(node%,mat_type%)"Win32" = GetProcAddress(DllHandle,"iNodeMaterialType")
Rem
bbdoc:
returns:
End Rem
Global iGetNodeByID%(id%)"Win32" = GetProcAddress(DllHandle,"iGetNodeByID")
Rem
bbdoc:
returns:
End Rem
Global iGetNodeByName%(name$z)"Win32" = GetProcAddress(DllHandle,"iGetNodeByName")


''  NODE CONTROL

Rem
bbdoc:
returns:
End Rem
Global iFreeNode%(node%)"Win32" = GetProcAddress(DllHandle,"iFreeNode")
Rem
bbdoc:
returns:
End Rem
Global iCopyNode%(node%,parent%)"Win32" = GetProcAddress(DllHandle,"iCopyNode")
Rem
bbdoc:
returns:
End Rem
Global iNodeTexture(node%,texture%,index%)"Win32" = GetProcAddress(DllHandle,"iNodeTexture")
Rem
bbdoc:
returns:
End Rem
Global iNodeColor(node%,r%,g%,b%,alpha%)"Win32" = GetProcAddress(DllHandle,"iNodeColor")
Rem
bbdoc:
returns:
End Rem
Global iNodeAlpha(node%,alpha%)"Win32" = GetProcAddress(DllHandle,"iNodeAlpha")
Rem
bbdoc:
returns:
End Rem
Global iNameNode(node%,name$z)"Win32" = GetProcAddress(DllHandle,"iNameNode")
Rem
bbdoc:
returns:
End Rem
Global iIDNode(node%,id%)"Win32" = GetProcAddress(DllHandle,"iIDNode")
Rem
bbdoc:
returns:
End Rem
Global iNodeParent(node%,parent%)"Win32" = GetProcAddress(DllHandle,"iNodeParent")
Rem
bbdoc:
returns:
End Rem
Global iGetParent%(node%)"Win32" = GetProcAddress(DllHandle,"iGetParent")
Rem
bbdoc:
returns:
End Rem
Global iShowNode(node%)"Win32" = GetProcAddress(DllHandle,"iShowNode")
Rem
bbdoc:
returns:
End Rem
Global iHideNode(node%)"Win32" = GetProcAddress(DllHandle,"iHideNode")
Rem
bbdoc:
returns:
End Rem
Global iNodeXScale#(node%)"Win32" = GetProcAddress(DllHandle,"iNodeXScale")
Rem
bbdoc:
returns:
End Rem
Global iNodeYScale#(node%)"Win32" = GetProcAddress(DllHandle,"iNodeYScale")
Rem
bbdoc:
returns:
End Rem
Global iNodeZScale#(node%)"Win32" = GetProcAddress(DllHandle,"iNodeZScale")
Rem
bbdoc:
returns:
End Rem
Global iGetNodeJoint%(node%,joint_name$z)"Win32" = GetProcAddress(DllHandle,"iGetNodeJoint")


''  NODE COLLISION  --  NOT COMPLETELY IMPLEMENTED YET!

Rem
bbdoc:
returns:
End Rem
Global iResetNode(node%)"Win32" = GetProcAddress(DllHandle,"iResetNode")
Rem
bbdoc:
returns:
End Rem
Global iNodeRadius(node%,x_raduis#,y_radius#)"Win32" = GetProcAddress(DllHandle,"iNodeRadius")
Rem
bbdoc:
returns:
End Rem
Global iNodeBox(node%,x#,y#,z#,width#,height#,depth#)"Win32" = GetProcAddress(DllHandle,"iNodeBox")
Rem
bbdoc:
returns:
End Rem
Global iNodeType(node%,collision_type%,recursive%)"Win32" = GetProcAddress(DllHandle,"iNodeType")
Rem
bbdoc:
returns:
End Rem
Global iNodePickMode(node%,pick_geometry%,obscurer%)"Win32" = GetProcAddress(DllHandle,"iNodePickMode")
Rem
bbdoc:
returns:
End Rem
Global iNodeCollided%(node%,ColType%)"Win32" = GetProcAddress(DllHandle,"iNodeCollided")
Rem
bbdoc:
returns:
End Rem
Global iCountCollisions%(node%)"Win32" = GetProcAddress(DllHandle,"iCountCollisions")
Rem
bbdoc:
returns:
End Rem
Global iCollisionX#(node%,index%)"Win32" = GetProcAddress(DllHandle,"iCollisionX")
Rem
bbdoc:
returns:
End Rem
Global iCollisionY#(node%,index%)"Win32" = GetProcAddress(DllHandle,"iCollisionY")
Rem
bbdoc:
returns:
End Rem
Global iCollisionZ#(node%,index%)"Win32" = GetProcAddress(DllHandle,"iCollisionZ")
Rem
bbdoc:
returns:
End Rem
Global iCollisionNX#(node%,index%)"Win32" = GetProcAddress(DllHandle,"iCollisionNX")
Rem
bbdoc:
returns:
End Rem
Global iCollisionNY#(node%,index%)"Win32" = GetProcAddress(DllHandle,"iCollisionNY")
Rem
bbdoc:
returns:
End Rem
Global iCollisionNZ#(node%,index%)"Win32" = GetProcAddress(DllHandle,"iCollisionNZ")
Rem
bbdoc:
returns:
End Rem
Global iCollisionTime%(node%,index%)"Win32" = GetProcAddress(DllHandle,"iCollisionTime")
Rem
bbdoc:
returns:
End Rem
Global iCollisionNode%(node%,index%)"Win32" = GetProcAddress(DllHandle,"iCollisionNode")
Rem
bbdoc:
returns:
End Rem
Global iCollisionSurface%(node%,index%)"Win32" = GetProcAddress(DllHandle,"iCollisionSurface")
Rem
bbdoc:
returns:
End Rem
Global iCollisionTriangle%(node%,index%)"Win32" = GetProcAddress(DllHandle,"iCollisionTriangle")
Rem
bbdoc:
returns:
End Rem
Global iGetNodeType%(node%)"Win32" = GetProcAddress(DllHandle,"iGetNodeType")
Rem
bbdoc:
returns:
End Rem
Global iGetScreenXFrom3DPosition(pos_x#,pos_y#,pos_z#)"Win32" = GetProcAddress(DllHandle,"iGetScreenXFrom3DPosition")
Rem
bbdoc:
returns:
End Rem
Global iGetScreenYFrom3DPosition(pos_x#,pos_y#,pos_z#)"Win32" = GetProcAddress(DllHandle,"iGetScreenYFrom3DPosition")
Rem
bbdoc:
returns:
End Rem
Global i3DPositionXFromScreen#(screenX%,screenY%,camera%,normalX#,normalY#,normalZ#,distanceFromOrigin#)"Win32" = GetProcAddress(DllHandle,"i3DPositionXFromScreen")
Rem
bbdoc:
returns:
End Rem
Global i3DPositionYFromScreen#(screenX%,screenY%,camera%,normalX#,normalY#,normalZ#,distanceFromOrigin#)"Win32" = GetProcAddress(DllHandle,"i3DPositionYFromScreen")
Rem
bbdoc:
returns:
End Rem
Global i3DPositionZFromScreen#(screenX%,screenY%,camera%,normalX#,normalY#,normalZ#,distanceFromOrigin#)"Win32" = GetProcAddress(DllHandle,"i3DPositionZFromScreen")


'	ORIGINAL COLLISION COMMANDS To BE RE-WRITTEN

Rem
bbdoc:
returns:
End Rem
Global iGetCollisionGroupFromMesh%(node%,frame%)"Win32" = GetProcAddress(DllHandle,"iGetCollisionGroupFromMesh")
Rem
bbdoc:
returns:
End Rem
Global iGetCollisionGroupFromComplexMesh%(mesh%,node%,frame%)"Win32" = GetProcAddress(DllHandle,"iGetCollisionGroupFromComplexMesh")
Rem
bbdoc:
returns:
End Rem
Global iGetCollisionGroupFromBox%(node%)"Win32" = GetProcAddress(DllHandle,"iGetCollisionGroupFromBox")
Rem
bbdoc:
returns:
End Rem
Global iGetCollisionGroupFromTerrain%(node%,level_of_detail%)"Win32" = GetProcAddress(DllHandle,"iGetCollisionGroupFromTerrain")
Rem
bbdoc:
returns:
End Rem
Global iAttachCollisionGroupToNode(collision%,node%)"Win32" = GetProcAddress(DllHandle,"iAttachCollisionGroupToNode")
Rem
bbdoc:
returns:
End Rem
Global iRemoveCollisionGroup(collision%,node%)"Win32" = GetProcAddress(DllHandle,"iRemoveCollisionGroup")
Rem
bbdoc:
returns:
End Rem
Global iSetNodeTriangleSelector(node%,collision%)"Win32" = GetProcAddress(DllHandle,"iSetNodeTriangleSelector")
Rem
bbdoc:
returns:
End Rem
Global iCreateCombinedCollisionGroup%()"Win32" = GetProcAddress(DllHandle,"iCreateCombinedCollisionGroup")
Rem
bbdoc:
returns:
End Rem
Global iAddCollisionGroupToCombination(combined_collision_group%,collision_group%)"Win32" = GetProcAddress(DllHandle,"iAddCollisionGroupToCombination")
Rem
bbdoc:
returns:
End Rem
Global iRemoveAllCollisionGroupsFromCombination(combined_collision_group%)"Win32" = GetProcAddress(DllHandle,"iRemoveAllCollisionGroupsFromCombination")
Rem
bbdoc:
returns:
End Rem
Global iRemoveCollisionGroupFromCombination(combined_collision_group%,collision_group%)"Win32" = GetProcAddress(DllHandle,"iRemoveCollisionGroupFromCombination")
Rem
bbdoc:
returns:
End Rem
Global iGetCollisionPoint%(start%,line_end%,collision_group%,collision_point%)"Win32" = GetProcAddress(DllHandle,"iGetCollisionPoint")
Rem
bbdoc:
returns:
End Rem
Global iGetRayFromScreenCoordinates(screen_x%,screen_y%,camera%,start%,line_end%)"Win32" = GetProcAddress(DllHandle,"iGetRayFromScreenCoordinates")
Rem
bbdoc:
returns:
End Rem
Global iGetCollisionNodeFromCamera%(camera%)"Win32" = GetProcAddress(DllHandle,"iGetCollisionNodeFromCamera")
Rem
bbdoc:
returns:
End Rem
Global iGetCollisionNodeFromRay%(x#,y#,z#,dx#,dy#,dz#)"Win32" = GetProcAddress(DllHandle,"iGetCollisionNodeFromRay")
Rem
bbdoc:
returns:
End Rem
Global iGetChildCollisionNodeFromRay%(node%,idMask%,recurse%,start%,line_end%)"Win32" = GetProcAddress(DllHandle,"iGetChildCollisionNodeFromRay")
Rem
bbdoc:
returns:
End Rem
Global iGetChildCollisionNodeFromPoint%(node%,idMask%,recurse%,point%)"Win32" = GetProcAddress(DllHandle,"iGetChildCollisionNodeFromPoint")
Rem
bbdoc:
returns:
End Rem
Global iGetCollisionNodeFromScreenCoordinates%(screen_x%,screen_y%)"Win32" = GetProcAddress(DllHandle,"iGetCollisionNodeFromScreenCoordinates")
Rem
bbdoc:
returns:
End Rem
Global iGetCollisionNodeAndPointFromRay%(sx#,sy#,sz#,ex#,ey#,ez#,id%,rootNode%)"Win32" = GetProcAddress(DllHandle,"iGetCollisionNodeAndPointFromRay")
Rem
bbdoc:
returns:
End Rem
Global iGet2DPositionFromScreenCoordinates(screenx%,screeny%,x#,y#,camera%)"Win32" = GetProcAddress(DllHandle,"iGet2DPositionFromScreenCoordinates")
Rem
bbdoc:
returns:
End Rem
Global iSetupIrrSceneCollision(camera%)"Win32" = GetProcAddress(DllHandle,"iSetupIrrSceneCollision")
Rem
bbdoc:
returns:
End Rem
Global iGetDistanceBetweenNodes#(nodeA%,nodeB%)"Win32" = GetProcAddress(DllHandle,"iGetDistanceBetweenNodes")
Rem
bbdoc:
returns:
End Rem
Global iAreNodesIntersecting%(nodeA%,nodeB%)"Win32" = GetProcAddress(DllHandle,"iAreNodesIntersecting")
Rem
bbdoc:
returns:
End Rem
Global iIsPointInsideNode%(nodeA%,X#,Y#,Z#)"Win32" = GetProcAddress(DllHandle,"iIsPointInsideNode")
Rem
bbdoc:
returns:
End Rem
Global iGetCollisionResultPosition(selector%,ellipsoidX#,ellipsoidY#,ellipsoidZ#,ellipsoidRadius#,velX#,velY#,velZ#,gravityX#,gravityY#,gravityZ#,slideSpeed#)"Win32" = GetProcAddress(DllHandle,"iGetCollisionResultPosition")
Rem
bbdoc:
returns:
End Rem
Global iCollFalling%()"Win32" = GetProcAddress(DllHandle,"iCollFalling")
Rem
bbdoc:
returns:
End Rem
Global iCollHitPositionX#()"Win32" = GetProcAddress(DllHandle,"iCollHitPositionX")
Rem
bbdoc:
returns:
End Rem
Global iCollHitPositionY#()"Win32" = GetProcAddress(DllHandle,"iCollHitPositionY")
Rem
bbdoc:
returns:
End Rem
Global iCollHitPositionZ#()"Win32" = GetProcAddress(DllHandle,"iCollHitPositionZ")
Rem
bbdoc:
returns:
End Rem
Global iCollNewPositionX#()"Win32" = GetProcAddress(DllHandle,"iCollNewPositionX")
Rem
bbdoc:
returns:
End Rem
Global iCollNewPositionY#()"Win32" = GetProcAddress(DllHandle,"iCollNewPositionY")
Rem
bbdoc:
returns:
End Rem
Global iCollNewPositionZ#()"Win32" = GetProcAddress(DllHandle,"iCollNewPositionZ")

''  BSP And FILE

Rem
bbdoc:
returns:
End Rem
Global iAddZipFile%(path$z,ignore_case%,ignore_paths%,password$z)"Win32" = GetProcAddress(DllHandle,"iAddZipFile")
Rem
bbdoc:
returns:
End Rem
Global iChangeWorkingDirectory(path$z)"Win32" = GetProcAddress(DllHandle,"iChangeWorkingDirectory")
Rem
bbdoc:
returns:
End Rem
Global iGetWorkingDirectory$z()"Win32" = GetProcAddress(DllHandle,"iGetWorkingDirectory")
Rem
bbdoc:
returns:
End Rem
Global iLoadOctreeMesh%(file$z)"Win32" = GetProcAddress(DllHandle,"iLoadOctreeMesh")
Rem
bbdoc:
returns:
End Rem
Global iAddOctreeMeshNode%(mesh%)"Win32" = GetProcAddress(DllHandle,"iAddOctreeMeshNode")


''  MODEL ANIMATION

Rem
bbdoc:
returns:
End Rem
Global iAnimateNode(node%,mode%,speed#,first_frame%,last_frame%,transition#)"Win32" = GetProcAddress(DllHandle,"iAnimateNode")
Rem
bbdoc:
returns:
End Rem
Global iPlayMD2Animation(node%,sequence%)"Win32" = GetProcAddress(DllHandle,"iPlayMD2Animation")
Rem
bbdoc:
returns:
End Rem
Global iLoopAnimation(node%,looped%)"Win32" = GetProcAddress(DllHandle,"iLoopAnimation")
Rem
bbdoc:
returns:
End Rem
Global iAnimationLooped(node%)"Win32" = GetProcAddress(DllHandle,"iAnimationLooped")
Rem
bbdoc:
returns:
End Rem
Global iAnimationSpeed(node%,speed#)"Win32" = GetProcAddress(DllHandle,"iAnimationSpeed")
Rem
bbdoc:
returns:
End Rem
Global iAnimationFrame%(node%)"Win32" = GetProcAddress(DllHandle,"iAnimationFrame")
Rem
bbdoc:
returns:
End Rem
Global iSetAnimationFrame(node%,frame#)"Win32" = GetProcAddress(DllHandle,"iSetAnimationFrame")
Rem
bbdoc:
returns:
End Rem
Global iTransitionTime(node%,speed#)"Win32" = GetProcAddress(DllHandle,"iTransitionTime")
Rem
bbdoc:
returns:
End Rem
Global iAnimateJoints(node%)"Win32" = GetProcAddress(DllHandle,"iAnimateJoints")
Rem
bbdoc:
returns:
End Rem
Global iSetJointMode(node%,mode%)"Win32" = GetProcAddress(DllHandle,"iSetJointMode")
Rem
bbdoc:
returns:
End Rem
Global iCollisionAnimator%(selector%,node%,radiusx#,radiusy#,radiusz#,gravityx#,gravityy#,gravityz#,offsetx#,offsety#,offsetz#)"Win32" = GetProcAddress(DllHandle,"iCollisionAnimator")
Rem
bbdoc:
returns:
End Rem
Global iDeleteAnimator%(node%,delete_after_n_milliseconds%)"Win32" = GetProcAddress(DllHandle,"iDeleteAnimator")
Rem
bbdoc:
returns:
End Rem
Global iFlyCircleAnimator%(node%,centre_x#,centre_y#,centre_z#,radius#,speed#)"Win32" = GetProcAddress(DllHandle,"iFlyCircleAnimator")
Rem
bbdoc:
returns:
End Rem
Global iFlyStraightAnimator%(node%,start_x#,start_y#,start_z#,end_x#,end_y#,end_z#,time_to_complete%,loop_path%)"Win32" = GetProcAddress(DllHandle,"iFlyStraightAnimator")
Rem
bbdoc:
returns:
End Rem
Global iRotationAnimator%(node%,x#,y#,z#)"Win32" = GetProcAddress(DllHandle,"iRotationAnimator")
Rem
bbdoc:
returns:
End Rem
Global iSplineAnimator%(node%,array_size%,x#,y#,z#,time_to_start%,speed#,tightness#)"Win32" = GetProcAddress(DllHandle,"iSplineAnimator")
Rem
bbdoc:
returns:
End Rem
Global iFadeAnimator%(node%,delete_after_n_milliseconds%,scale#)"Win32" = GetProcAddress(DllHandle,"iFadeAnimator")
Rem
bbdoc:
returns:
End Rem
Global iFreeAnimator(node%,animnode%)"Win32" = GetProcAddress(DllHandle,"iFreeAnimator")


''  MESH

Rem
bbdoc:
returns:
End Rem
Global iCreateMesh%(mesh_name$z,vertex_count%,vertices%,indices_count%,indices%)"Win32" = GetProcAddress(DllHandle,"iCreateMesh")
Rem
bbdoc:
returns:
End Rem
Global iWriteMesh%(mesh%,file_format%,path$z)"Win32" = GetProcAddress(DllHandle,"iWriteMesh")
Rem
bbdoc:
returns:
End Rem
Global iClearUnusedMeshes()"Win32" = GetProcAddress(DllHandle,"iClearUnusedMeshes")
Rem
bbdoc:
returns:
End Rem
Global iFreeMesh(mesh%)"Win32" = GetProcAddress(DllHandle,"iFreeMesh")
Rem
bbdoc:
returns:
End Rem
Global iNameMesh(mesh%,newName$z)"Win32" = GetProcAddress(DllHandle,"iNameMesh")
Rem
bbdoc:
returns:
End Rem
Global iLoadMesh%(file$z)"Win32" = GetProcAddress(DllHandle,"iLoadMesh")
Rem
bbdoc:
returns:
End Rem
Global iLoadMeshNode%(file$z,parent%)"Win32" = GetProcAddress(DllHandle,"iLoadMeshNode")
Rem
bbdoc:
returns:
End Rem
Global iLoadAnimMesh%(file$z,parent%)"Win32" = GetProcAddress(DllHandle,"iLoadAnimMesh")
Rem
bbdoc:
returns:
End Rem
Global iCreateCube%(size#,parent%)"Win32" = GetProcAddress(DllHandle,"iCreateCube")
Rem
bbdoc:
returns:
End Rem
Global iCreateSphere%(polycount%,parent%)"Win32" = GetProcAddress(DllHandle,"iCreateSphere")
Rem
bbdoc:
returns:
End Rem
Global iCopyMesh%(mesh%)"Win32" = GetProcAddress(DllHandle,"iCopyMesh")
Rem
bbdoc:
returns:
End Rem
Global iScaleMesh(mesh%,scale#,frame%,meshBuffer%,mesh2%)"Win32" = GetProcAddress(DllHandle,"iScaleMesh")
Rem
bbdoc:
returns:
End Rem
Global iCreateHillPlaneMesh%(mesh_name$z,tileSizeX#,tileSizeY#,tileCountX%,tileCountY%,material%,hillHeight#,countHillsX#,countHillsY#,textureRepeatCountX#,textureRepeatCountY#)"Win32" = GetProcAddress(DllHandle,"iCreateHillPlaneMesh")
Rem
bbdoc:
returns:
End Rem
Global iFlipMesh%(mesh%)"Win32" = GetProcAddress(DllHandle,"iFlipMesh")
Rem
bbdoc:
returns:
End Rem
Global iFlipNodeMesh%(node%)"Win32" = GetProcAddress(DllHandle,"iFlipNodeMesh")
Rem
bbdoc:
returns:
End Rem
Global iHWAcceleratedMesh(mesh%,frame%)"Win32" = GetProcAddress(DllHandle,"iHWAcceleratedMesh")
Rem
bbdoc:
returns:
End Rem
Global iHWAcceleratedMeshNode(node%,frame%)"Win32" = GetProcAddress(DllHandle,"iHWAcceleratedMeshNode")
Rem
bbdoc:
returns:
End Rem
Global iGetNodeMesh%(node%)"Win32" = GetProcAddress(DllHandle,"iGetNodeMesh")
Rem
bbdoc:
returns:
End Rem
Global iAddMeshToScene%(mesh%)"Win32" = GetProcAddress(DllHandle,"iAddMeshToScene")
Rem
bbdoc:
returns:
End Rem
Global iCreateBatchingMesh%()"Win32" = GetProcAddress(DllHandle,"iCreateBatchingMesh")
Rem
bbdoc:
returns:
End Rem
Global iAddToBatchingMesh(meshBatch%,mesh%,posX#,posY#,posZ#,rotX#,rotY#,rotZ#,scaleX#,scaleY#,scaleZ#)"Win32" = GetProcAddress(DllHandle,"iAddToBatchingMesh")
Rem
bbdoc:
returns:
End Rem
Global iFinalizeBatchingMesh%(meshBatch%)"Win32" = GetProcAddress(DllHandle,"iFinalizeBatchingMesh")
Rem
bbdoc:
returns:
End Rem
Global iMeshTexture(mesh%,texture%,material_index%,buffer%)"Win32" = GetProcAddress(DllHandle,"iMeshTexture")
Rem
bbdoc:
returns:
End Rem
Global iMeshFrameCount%(mesh%)"Win32" = GetProcAddress(DllHandle,"iMeshFrameCount")
Rem
bbdoc:
returns:
End Rem
Global iMeshBufferCount%(mesh%,frame%)"Win32" = GetProcAddress(DllHandle,"iMeshBufferCount")
Rem
bbdoc:
returns:
End Rem
Global iMeshIndexCount%(mesh%,frame%,meshBuffer%)"Win32" = GetProcAddress(DllHandle,"iMeshIndexCount")
Rem
bbdoc:
returns:
End Rem
Global iCopyMeshIndicesTo(mesh%,frame%,indicies%,meshBuffer%)"Win32" = GetProcAddress(DllHandle,"iCopyMeshIndicesTo")
Rem
bbdoc:
returns:
End Rem
Global iCopyMeshIndicesFrom(mesh%,frame%,indicies%,meshBuffer%)"Win32" = GetProcAddress(DllHandle,"iCopyMeshIndicesFrom")
Rem
bbdoc:
returns:
End Rem
Global iMeshVertexCount%(mesh%,frame%,meshBuffer%)"Win32" = GetProcAddress(DllHandle,"iMeshVertexCount")
Rem
bbdoc:
returns:
End Rem
Global iCopyMeshVerticesTo(mesh%,frame%,verticies%,meshBuffer%)"Win32" = GetProcAddress(DllHandle,"iCopyMeshVerticesTo")
Rem
bbdoc:
returns:
End Rem
Global iCopyMeshVerticesFrom(mesh%,frame%,verticies%,meshBuffer%)"Win32" = GetProcAddress(DllHandle,"iCopyMeshVerticesFrom")
Rem
bbdoc:
returns:
End Rem
Global iMeshVertexMemory%(mesh%,frame%,meshBuffer%)"Win32" = GetProcAddress(DllHandle,"iMeshVertexMemory")
Rem
bbdoc:
returns:
End Rem
Global iMeshVertexColors(mesh%,frame%,VertexColor%,groupAmount%,startPos%,endPos%,meshbuffer%)"Win32" = GetProcAddress(DllHandle,"iMeshVertexColors")
Rem
bbdoc:
returns:
End Rem
Global iMeshVertexCoords(mesh%,frame%,vertexCoord%,groupAmount%,startPos%,endPos%,meshbuffer%)"Win32" = GetProcAddress(DllHandle,"iMeshVertexCoords")
Rem
bbdoc:
returns:
End Rem
Global iMeshVertexSingleColor(mesh%,frame%,VertexColor%,groupAmount%,startPos%,endPos%,meshbuffer%)"Win32" = GetProcAddress(DllHandle,"iMeshVertexSingleColor")
Rem
bbdoc:
returns:
End Rem
Global iMeshBoundingBox(mesh%,minX#,minY#,minZ#,maxX#,maxY#,maxZ#)"Win32" = GetProcAddress(DllHandle,"iMeshBoundingBox")
Rem
bbdoc:
returns:
End Rem
Global iStaticMeshForNormalMapping%(mesh%)"Win32" = GetProcAddress(DllHandle,"iStaticMeshForNormalMapping")


''  PLANE

Rem
bbdoc:
returns:
End Rem
Global iCreatePlane%(mesh_name$z)"Win32" = GetProcAddress(DllHandle,"iCreatePlane")


''  TEXTURE

Rem
bbdoc:
returns:
End Rem
Global iTextureCreateFlag(flag%,value%)"Win32" = GetProcAddress(DllHandle,"iTextureCreateFlag")
Rem
bbdoc:
returns:
End Rem
Global iCreateTexture%(name$z,x%,y%,format%)"Win32" = GetProcAddress(DllHandle,"iCreateTexture")
Rem
bbdoc:
returns:
End Rem
Global iLoadTexture%(file$z)"Win32" = GetProcAddress(DllHandle,"iLoadTexture")
Rem
bbdoc:
returns:
End Rem
Global iCreateRenderTexture%(x%,y%)"Win32" = GetProcAddress(DllHandle,"iCreateRenderTexture")
Rem
bbdoc:
returns:
End Rem
Global iDrawSceneToTexture(texture%)"Win32" = GetProcAddress(DllHandle,"iDrawSceneToTexture")
Rem
bbdoc:
returns:
End Rem
Global iRenderTargetTexture(texture%,sceneBackgroundColor%,clearBackBuffer%,clearZBuffer%)"Win32" = GetProcAddress(DllHandle,"iRenderTargetTexture")
Rem
bbdoc:
returns:
End Rem
Global iFreeTexture(texture%)"Win32" = GetProcAddress(DllHandle,"iFreeTexture")
Rem
bbdoc:
returns:
End Rem
Global iTextureBlend%(destination_texture%,source_texture%,x_offset%,y_offset%,operation%)"Win32" = GetProcAddress(DllHandle,"iTextureBlend")
Rem
bbdoc:
returns:
End Rem
Global iTextureWidth%(texture%)"Win32" = GetProcAddress(DllHandle,"iTextureWidth")
Rem
bbdoc:
returns:
End Rem
Global iTextureHeight%(texture%)"Win32" = GetProcAddress(DllHandle,"iTextureHeight")
Rem
bbdoc:
returns:
End Rem
Global iMaskTexture(texture%,red%,green%,blue%,alpha%)"Win32" = GetProcAddress(DllHandle,"iMaskTexture")
Rem
bbdoc:
returns:
End Rem
Global iLockTexture%(texture%)"Win32" = GetProcAddress(DllHandle,"iLockTexture")
Rem
bbdoc:
returns:
End Rem
Global iUnlockTexture(texture%)"Win32" = GetProcAddress(DllHandle,"iUnlockTexture")
Rem
bbdoc:
returns:
End Rem
Global iNormalMapTexture(texture%,amplitude#)"Win32" = GetProcAddress(DllHandle,"iNormalMapTexture")


''	Material and GPU Programming Functions

Rem
bbdoc:
returns:
End Rem
Global iNodeAmbientColor(node%,uColor%)"Win32" = GetProcAddress(DllHandle,"iNodeAmbientColor")
Rem
bbdoc:
returns:
End Rem
Global iNodeDiffuseColor(node%,uColor%)"Win32" = GetProcAddress(DllHandle,"iNodeDiffuseColor")
Rem
bbdoc:
returns:
End Rem
Global iNodeSpecularColor(node%,uColor%)"Win32" = GetProcAddress(DllHandle,"iNodeSpecularColor")
Rem
bbdoc:
returns:
End Rem
Global iNodeEmissiveColor(node%,uColor%)"Win32" = GetProcAddress(DllHandle,"iNodeEmissiveColor")
Rem
bbdoc:
returns:
End Rem
Global iNodeColorByVertex(node%,colorMaterial%)"Win32" = GetProcAddress(DllHandle,"iNodeColorByVertex")
Rem
bbdoc:
returns:
End Rem
Global iMaterialVertexColorAffects(material%,colorMaterial%)"Win32" = GetProcAddress(DllHandle,"iMaterialVertexColorAffects")
Rem
bbdoc:
returns:
End Rem
Global iMaterialShininess(material%,shininess#)"Win32" = GetProcAddress(DllHandle,"iMaterialShininess")
Rem
bbdoc:
returns:
End Rem
Global iMaterialSpecularColor(material%,Alpha%,Red%,Green%,Blue%)"Win32" = GetProcAddress(DllHandle,"iMaterialSpecularColor")
Rem
bbdoc:
returns:
End Rem
Global iMaterialDiffuseColor(material%,Alpha%,Red%,Green%,Blue%)"Win32" = GetProcAddress(DllHandle,"iMaterialDiffuseColor")
Rem
bbdoc:
returns:
End Rem
Global iMaterialAmbientColor(material%,Alpha%,Red%,Green%,Blue%)"Win32" = GetProcAddress(DllHandle,"iMaterialAmbientColor")
Rem
bbdoc:
returns:
End Rem
Global iMaterialEmissiveColor(material%,Alpha%,Red%,Green%,Blue%)"Win32" = GetProcAddress(DllHandle,"iMaterialEmissiveColor")
Rem
bbdoc:
returns:
End Rem
Global iMaterialTypeParam(material%,value#)"Win32" = GetProcAddress(DllHandle,"iMaterialTypeParam")
Rem
bbdoc:
returns:
End Rem
Global iMaterialBlend(material%,blendSrc%,blendDest%)"Win32" = GetProcAddress(DllHandle,"iMaterialBlend")
Rem
bbdoc:
returns:
End Rem
Global iMaterialLineThickness(material%,value#)"Win32" = GetProcAddress(DllHandle,"iMaterialLineThickness")
Rem
bbdoc:
returns:
End Rem
Global iCreateNamedVertexShaderConstant%(shader%,const_name$,const_preset%,const_data#,data_count%)"Win32" = GetProcAddress(DllHandle,"iCreateNamedVertexShaderConstant")
Rem
bbdoc:
returns:
End Rem
Global iCreateNamedPixelShaderConstant%(shader%,const_name$,const_preset%,const_data#,data_count%)"Win32" = GetProcAddress(DllHandle,"iCreateNamedPixelShaderConstant")
Rem
bbdoc:
returns:
End Rem
Global iCreateAddressedVertexShaderConstant%(shader%,const_address%,const_preset%,const_data#,data_count%)"Win32" = GetProcAddress(DllHandle,"iCreateAddressedVertexShaderConstant")
Rem
bbdoc:
returns:
End Rem
Global iCreateAddressedPixelShaderConstant%(shader%,const_address%,const_preset%,const_data#,data_count%)"Win32" = GetProcAddress(DllHandle,"iCreateAddressedPixelShaderConstant")
Rem
bbdoc:
returns:
End Rem
Global iAddHighLevelShaderMaterial%(vertex_program$,vertex_start_function$,vertex_prog_type%,pixel_program$,pixel_start_function$,pixel_prog_type%,material_type%)"Win32" = GetProcAddress(DllHandle,"iAddHighLevelShaderMaterial")
Rem
bbdoc:
returns:
End Rem
Global iAddHighLevelShaderMaterialFromFiles%(vertex_program_filename$,vertex_start_function$,vertex_prog_type%,pixel_program_filename$,pixel_start_function$,pixel_prog_type%,material_type%)"Win32" = GetProcAddress(DllHandle,"iAddHighLevelShaderMaterialFromFiles")
Rem
bbdoc:
returns:
End Rem
Global iAddShaderMaterial%(vertex_program$,pixel_program$,material_type%)"Win32" = GetProcAddress(DllHandle,"iAddShaderMaterial")
Rem
bbdoc:
returns:
End Rem
Global iAddShaderMaterialFromFiles%(vertex_program_filename$,pixel_program_filename$,material_type%)"Win32" = GetProcAddress(DllHandle,"iAddShaderMaterialFromFiles")
Rem
bbdoc:
returns:
End Rem
Global itMaterialCount%(node%)"Win32" = GetProcAddress(DllHandle,"iMaterialCount")
Rem
bbdoc:
returns:
End Rem
Global iGetMaterial%(node%,index%)"Win32" = GetProcAddress(DllHandle,"iGetMaterial")


''  IMAGE

Rem
bbdoc:
returns:
End Rem
Global iLoadImage%(path$z)"Win32" = GetProcAddress(DllHandle,"iLoadImage")
Rem
bbdoc:
returns:
End Rem
Global iCreateImage%(x%,y%,format%)"Win32" = GetProcAddress(DllHandle,"iCreateImage")
Rem
bbdoc:
returns:
End Rem
Global iFreeImage(image%)"Win32" = GetProcAddress(DllHandle,"iFreeImage")
Rem
bbdoc:
returns:
End Rem
Global iLockImage%(image%)"Win32" = GetProcAddress(DllHandle,"iLockImage")
Rem
bbdoc:
returns:
End Rem
Global iUnlockImage(image%)"Win32" = GetProcAddress(DllHandle,"iUnlockImage")
Rem
bbdoc:
returns:
End Rem
Global iSaveScreenShot(Text$z)"Win32" = GetProcAddress(DllHandle,"iSaveScreenShot")
Rem
bbdoc:
returns:
End Rem
Global iGrabScreenShot%(x%,y%,w%,h%)"Win32" = GetProcAddress(DllHandle,"iGrabScreenShot")
Rem
bbdoc:
returns:
End Rem
Global iImageWidth%(image%)"Win32" = GetProcAddress(DllHandle,"iImageWidth")
Rem
bbdoc:
returns:
End Rem
Global iImageHeight%(image%)"Win32" = GetProcAddress(DllHandle,"iImageHeight")
Rem
bbdoc:
returns:
End Rem
Global iImagePitch%(image%)"Win32" = GetProcAddress(DllHandle,"iImagePitch")
Rem
bbdoc:
returns:
End Rem
Global iImageFormat%(image%)"Win32" = GetProcAddress(DllHandle,"iImageFormat")
Rem
bbdoc:
returns:
End Rem
Global iDrawImage(texture%,x%,y%)"Win32" = GetProcAddress(DllHandle,"iDrawImage")
Rem
bbdoc:
returns:
End Rem
Global iDrawImageElement(texture%,x%,y%,source_tx%,source_ty%,source_bx%,source_by%,usealpha%)"Win32" = GetProcAddress(DllHandle,"iDrawImageElement")
Rem
bbdoc:
returns:
End Rem
Global iDrawImageElementScale(texture%,dest_tx%,dest_ty%,dest_bx%,dest_by%,source_tx%,source_ty%,source_bx%,source_by%,usealpha%)"Win32" = GetProcAddress(DllHandle,"iDrawImageElementScale")


''  CAMERA

Rem
bbdoc:
returns:
End Rem
Global iCreateFPSCamera%(parent%,rotateSpeed#,moveSpeed#,id%,keyMapArray:Byte Ptr,keyMapSize%,noVericalMovement%,jumpSpeed#)"Win32" = GetProcAddress(DllHandle,"iCreateFPSCamera")
Rem
bbdoc:
returns:
End Rem
Global iCreateCamera%(parent%)"Win32" = GetProcAddress(DllHandle,"iCreateCamera")
Rem
bbdoc:
returns:
End Rem
Global iCreateMayaCamera%(parent%,rotateSpeed#,zoomSpeed#,moveSpeed#)"Win32" = GetProcAddress(DllHandle,"iCreateMayaCamera")
Rem
bbdoc:
returns:
End Rem
Global iCameraTarget(camera%,X#,Y#,Z#)"Win32" = GetProcAddress(DllHandle,"iCameraTarget")
Rem
bbdoc:
returns:
End Rem
Global iCameraTargetX#(camera%)"Win32" = GetProcAddress(DllHandle,"iCameraTargetX")
Rem
bbdoc:
returns:
End Rem
Global iCameraTargetY#(camera%)"Win32" = GetProcAddress(DllHandle,"iCameraTargetY")
Rem
bbdoc:
returns:
End Rem
Global iCameraTargetZ#(camera%)"Win32" = GetProcAddress(DllHandle,"iCameraTargetZ")
Rem
bbdoc:
returns:
End Rem
Global iCameraUpX#(camera%)"Win32" = GetProcAddress(DllHandle,"iCameraUpX")
Rem
bbdoc:
returns:
End Rem
Global iCameraUpY#(camera%)"Win32" = GetProcAddress(DllHandle,"iCameraUpY")
Rem
bbdoc:
returns:
End Rem
Global iCameraUpZ#(camera%)"Win32" = GetProcAddress(DllHandle,"iCameraUpZ")
Rem
bbdoc:
returns:
End Rem
Global iCameraUp(camera%,X#,Y#,Z#)"Win32" = GetProcAddress(DllHandle,"iCameraUp")
Rem
bbdoc:
returns:
End Rem
Global iCameraForwardX#(camera%)"Win32" = GetProcAddress(DllHandle,"iCameraForwardX")
Rem
bbdoc:
returns:
End Rem
Global iCameraForwardY#(camera%)"Win32" = GetProcAddress(DllHandle,"iCameraForwardY")
Rem
bbdoc:
returns:
End Rem
Global iCameraForwardZ#(camera%)"Win32" = GetProcAddress(DllHandle,"iCameraForwardZ")
Rem
bbdoc:
returns:
End Rem
Global iCameraRightX#(camera%)"Win32" = GetProcAddress(DllHandle,"iCameraRightX")
Rem
bbdoc:
returns:
End Rem
Global iCameraRightY#(camera%)"Win32" = GetProcAddress(DllHandle,"iCameraRightY")
Rem
bbdoc:
returns:
End Rem
Global iCameraRightZ#(camera%)"Win32" = GetProcAddress(DllHandle,"iCameraRight")
Rem
bbdoc:
returns:
End Rem
Global iCameraRange(camera%,farDistance#,nearDistance#)"Win32" = GetProcAddress(DllHandle,"iCameraRange")
Rem
bbdoc:
returns:
End Rem
Global iActiveCamera(camera%)"Win32" = GetProcAddress(DllHandle,"iActiveCamera")
Rem
bbdoc:
returns:
End Rem
Global iCameraFOV(camera%,fov#)"Win32" = GetProcAddress(DllHandle,"iCameraFOV")
Rem
bbdoc:
returns:
End Rem
Global iCameraAspectRatio(camera%,aspectRatio#)"Win32" = GetProcAddress(DllHandle,"iCameraAspectRatio")


''  TERRAINS

Rem
bbdoc:
returns:
End Rem
Global iLoadTerrain:Int(path$z,xPosition#,yPosition#,zPosition#,xRotation#,yRotation#,zRotation#,xScale#,yScale#,zScale#,VertexAlpha%,VertexRed%,VertexGreen%,VertexBlue%,smoothing%,maxLOD%,patchSize%)"Win32" = GetProcAddress(DllHandle,"iLoadTerrain")
Rem
bbdoc:
returns:
End Rem
Global iCreateTiledTerrain%(heightMapPath$z,texturePath$z,followNode%,terrainWidth%,TerrainHeight%,tileSize#,meshSize%,heightmapScale#,smoothing%,materialType%)"Win32" = GetProcAddress(DllHandle,"iCreateTiledTerrain")
Rem
bbdoc:
returns:
End Rem
Global iTiledTerrainHeight#(terrain%,X#,Z#)"Win32" = GetProcAddress(DllHandle,"iTiledTerrainHeight")
Rem
bbdoc:
returns:
End Rem
Global iTerrainHeight#(terrain%,X#,Z#)"Win32" = GetProcAddress(DllHandle,"iTerrainHeight")
Rem
bbdoc:
returns:
End Rem
Global iScaleTerrainTexture(terrain%,X#,Y#)"Win32" = GetProcAddress(DllHandle,"iScaleTerrainTexture")
Rem
bbdoc:
returns:
End Rem
Global iScaleSphericalTexture(terrain%,X#,Y#)"Win32" = GetProcAddress(DllHandle,"iScaleSphericalTexture")
Rem
bbdoc:
returns:
End Rem
Global iScaleTileTexture(terrain%,X#,Y#)"Win32" = GetProcAddress(DllHandle,"iScaleTileTexture")
Rem
bbdoc:
returns:
End Rem
Global iAttachTile(terrain%,neighbour%,Edge%)"Win32" = GetProcAddress(DllHandle,"iAttachTile")
Rem
bbdoc:
returns:
End Rem
Global iLoadTileStructure(terrain%,image%,dataX%,dataY%)"Win32" = GetProcAddress(DllHandle,"iLoadTileStructure")
Rem
bbdoc:
returns:
End Rem
Global iLoadTileColor(terrain%,image%,dataX%,dataY%)"Win32" = GetProcAddress(DllHandle,"iLoadTileColor")
Rem
bbdoc:
returns:
End Rem
Global iCreateSphericalTerrain%(topPath$z,frontPath$z,backPath$z,leftPath$z,rightPath$z,bottomPath$z,xPosition#,yPosition#,zPosition#,xRotation#,yRotation#,zRotation#,xScale#,yScale#,zScale#,VertexAlpha%,VertexRed%,VertexGreen%,VertexBlue%,smoothing%,spherical%,maxLOD%,patchSize%)"Win32" = GetProcAddress(DllHandle,"iCreateSphericalTerrain")
Rem
bbdoc:
returns:
End Rem
Global iSphericalTerrainTexture(terrain%,topTexture%,frontTexture%,backTexture%,leftTexture%,rightTexture%,bottomTexture%,materialIndex%)"Win32" = GetProcAddress(DllHandle,"iSphericalTerrainTexture")
Rem
bbdoc:
returns:
End Rem
Global iSphericalTerrainVertexColor(terrain%,topImage%,frontImage%,backImage%,leftImage%,rightImage%,bottomImage%)"Win32" = GetProcAddress(DllHandle,"iSphericalTerrainVertexColor")
Rem
bbdoc:
returns:
End Rem
Global iSphericalTerrainSurfaceX#(terrain%,face%,logicalX#,logicalZ#)"Win32" = GetProcAddress(DllHandle,"iSphericalTerrainSurfaceX")
Rem
bbdoc:
returns:
End Rem
Global iSphericalTerrainSurfaceY#(terrain%,face%,logicalX#,logicalZ#)"Win32" = GetProcAddress(DllHandle,"iSphericalTerrainSurfaceY")
Rem
bbdoc:
returns:
End Rem
Global iSphericalTerrainSurfaceZ#(terrain%,face%,logicalX#,logicalZ#)"Win32" = GetProcAddress(DllHandle,"iSphericalTerrainSurfaceZ")
Rem
bbdoc:
returns:
End Rem
Global iSphericalTerrainAngleRX#(terrain%,face%,logicalX#,logicalZ#)"Win32" = GetProcAddress(DllHandle,"iSphericalTerrainAngleRX")
Rem
bbdoc:
returns:
End Rem
Global iSphericalTerrainAngleRY#(terrain%,face%,logicalX#,logicalZ#)"Win32" = GetProcAddress(DllHandle,"iSphericalTerrainAngleRY")
Rem
bbdoc:
returns:
End Rem
Global iSphericalTerrainAngleRZ#(terrain%,face%,logicalX#,logicalZ#)"Win32" = GetProcAddress(DllHandle,"iSphericalTerrainAngleRZ")
Rem
bbdoc:
returns:
End Rem
Global iSphericalSurfaceLogicalX#(terrain%,X#,Y#,Z#,face%)"Win32" = GetProcAddress(DllHandle,"iSphericalSurfaceLogicalX")
Rem
bbdoc:
returns:
End Rem
Global iSphericalSurfaceLogicalZ#(terrain%,X#,Y#,Z#,face%)"Win32" = GetProcAddress(DllHandle,"iSphericalSurfaceLogicalZ")


''  LIGHTS

Rem
bbdoc:
returns:
End Rem
Global iCreateLight%(parent%,x#,y#,z#,red#,green#,blue#,size#)"Win32" = GetProcAddress(DllHandle,"iCreateLight")
Rem
bbdoc:
returns:
End Rem
Global iLightAmbientColor(light%,R#,G#,B#)"Win32" = GetProcAddress(DllHandle,"iLightAmbientColor")
Rem
bbdoc:
returns:
End Rem
Global iLightDiffuseColor(light%,R#,G#,B#)"Win32" = GetProcAddress(DllHandle,"iLightDiffuseColor")
Rem
bbdoc:
returns:
End Rem
Global iLightRange(light%,constant#,linear#,quadratic#)"Win32" = GetProcAddress(DllHandle,"iLightRange")
Rem
bbdoc:
returns:
End Rem
Global iLightCastShadows(light%,cast_shadows%)"Win32" = GetProcAddress(DllHandle,"iLightCastShadows")
Rem
bbdoc:
returns:
End Rem
Global iLightFalloff(light%,Falloff#)"Win32" = GetProcAddress(DllHandle,"iLightFalloff")
Rem
bbdoc:
returns:
End Rem
Global iLightConeAngle(light%,InnerCone#,OuterCone#)"Win32" = GetProcAddress(DllHandle,"iLightConeAngle")
Rem
bbdoc:
returns:
End Rem
Global iLightRadius(light%,Radius#)"Win32" = GetProcAddress(DllHandle,"iLightRadius")
Rem
bbdoc:
returns:
End Rem
Global iLightSpecularColor(light%,R#,G#,B#)"Win32" = GetProcAddress(DllHandle,"iLightSpecularColor")
Rem
bbdoc:
returns:
End Rem
Global iLightType(light%,light_type%)"Win32" = GetProcAddress(DllHandle,"iLightType")


''  PARTICLES

Rem
bbdoc:
returns:
End Rem
Global iCreateParticleSystem%(add_emitter%,parent%,id%,posX#,posY#,posZ#,rotX#,rotY#,rotZ#,scaleX#,scaleY#,scaleZ#)"Win32" = GetProcAddress(DllHandle,"iCreateParticleSystem")
Rem
bbdoc:
returns:
End Rem
Global iParticleSize(particle_emitter%,X#,Y#)"Win32" = GetProcAddress(DllHandle,"iParticleSize")
Rem
bbdoc:
returns:
End Rem
Global iParticleMinSize(particle_emitter%,X#,Y#)"Win32" = GetProcAddress(DllHandle,"iParticleMinSize")
Rem
bbdoc:
returns:
End Rem
Global iParticleMaxSize(particle_emitter%,X#,Y#)"Win32" = GetProcAddress(DllHandle,"iParticleMaxSize")
Rem
bbdoc:
returns:
End Rem
Global iCreateParticleEmitter%(particle_system%,min_box_x#,min_box_y#,min_box_z#,max_box_x#,max_box_y#,max_box_z#,dir_x#,dir_y#,dir_z#,min_paritlcles_ps%,max_paritlcles_ps%,min_start_red%,min_start_green%,min_start_blue%,max_start_red%,max_start_green%,max_start_blue%,min_lifetime%,max_lifetime%,min_start_sizeX#,min_start_sizeY#,max_start_sizeX#,max_start_sizeY#,max_angle_degrees%)"Win32" = GetProcAddress(DllHandle,"iCreateParticleEmitter")
Rem
bbdoc:
returns:
End Rem
Global iCreateAnimatedMeshSceneNodeEmitter%(particle_system%,node%,use_normal_direction%,normal_direction_modifier#,emit_from_every_vertex%,settings%)"Win32" = GetProcAddress(DllHandle,"iCreateAnimatedMeshSceneNodeEmitter")
Rem
bbdoc:
returns:
End Rem
Global iFadeOutAffector%(particle_system%,fade_speed%,fade_to_red%,fade_to_green%,fade_to_blue%)"Win32" = GetProcAddress(DllHandle,"iFadeOutAffector")
Rem
bbdoc:
returns:
End Rem
Global iGravityAffector%(particle_system%,x#,y#,z#,timeForceLost%)"Win32" = GetProcAddress(DllHandle,"iGravityAffector")
Rem
bbdoc:
returns:
End Rem
Global iAttractionAffector%(particle_system%,x#,y#,z#,speed#,attract%,affectX%,affectY%,affectZ%)"Win32" = GetProcAddress(DllHandle,"iAttractionAffector")
Rem
bbdoc:
returns:
End Rem
Global iRotationAffector%(particle_system%,Speed_X#,Speed_Y#,Speed_Z#,pivot_X#,pivot_Y#,pivot_Z#)"Win32" = GetProcAddress(DllHandle,"iRotationAffector")
Rem
bbdoc:
returns:
End Rem
Global iStopAffector%(particle_system%,run_time%,target_emitter%)"Win32" = GetProcAddress(DllHandle,"iStopAffector")
Rem
bbdoc:
returns:
End Rem
Global iPushAffector%(particle_system%,x#,y#,z#,speedX#,speedY#,speedZ#,far#,near#,column#,radial%)"Win32" = GetProcAddress(DllHandle,"iPushAffector")
Rem
bbdoc:
returns:
End Rem
Global iColorAffector%(particle_system%,num%,colors:Byte Ptr,times:Byte Ptr,smooth%)"Win32" = GetProcAddress(DllHandle,"iColorAffector")
Rem
bbdoc:
returns:
End Rem
Global iSplineAffector%(particle_system%,VertexCount%,verticies:Int Ptr,speed#,tightness#,attraction#,deleteAtEnd%)"Win32" = GetProcAddress(DllHandle,"iSplineAffector")
Rem
bbdoc:
returns:
End Rem
Global iFreeAffectors(particle_system%)"Win32" = GetProcAddress(DllHandle,"iFreeAffectors")
Rem
bbdoc:
returns:
End Rem
Global iParticleEmitterDirection(particle_system%,x#,y#,z#)"Win32" = GetProcAddress(DllHandle,"iParticleEmitterDirection")
Rem
bbdoc:
returns:
End Rem
Global iEmitterMinParticlesPerSecond(particle_system%,minPPS%)"Win32" = GetProcAddress(DllHandle,"iEmitterMinParticlesPerSecond")
Rem
bbdoc:
returns:
End Rem
Global iEmitterMaxParticlesPerSecond(particle_system%,maxPPS%)"Win32" = GetProcAddress(DllHandle,"iEmitterMaxParticlesPerSecond")
Rem
bbdoc:
returns:
End Rem
Global iEmitterMinStartColor(particle_system%,Red%,Green%,Blue%)"Win32" = GetProcAddress(DllHandle,"iEmitterMinStartColor")
Rem
bbdoc:
returns:
End Rem
Global iEmitterMaxStartColor(particle_system%,Red%,Green%,Blue%)"Win32" = GetProcAddress(DllHandle,"iEmitterMaxStartColor")
Rem
bbdoc:
returns:
End Rem
Global iParticleAffectorEnable(affector%,enable%)"Win32" = GetProcAddress(DllHandle,"iParticleAffectorEnable")
Rem
bbdoc:
returns:
End Rem
Global iFadeOutParticleAffectorTime(affector%,fade_speed%)"Win32" = GetProcAddress(DllHandle,"iFadeOutParticleAffectorTime")
Rem
bbdoc:
returns:
End Rem
Global iFadeOutParticleAffectorTargetColor(affector%,fade_to_red%,fade_to_green%,fade_to_blue%)"Win32" = GetProcAddress(DllHandle,"iFadeOutParticleAffectorTargetColor")
Rem
bbdoc:
returns:
End Rem
Global iGravityParticleAffectorDirection(affector%,x#,y#,z#)"Win32" = GetProcAddress(DllHandle,"iGravityParticleAffectorDirection")
Rem
bbdoc:
returns:
End Rem
Global iGravityParticleAffectorTimeForceLost(affector%,time_Force_Lost#)"Win32" = GetProcAddress(DllHandle,"iGravityParticleAffectorTimeForceLost")
Rem
bbdoc:
returns:
End Rem
Global iParticleAttractionAffectorAffectX(affector%,affect_x%)"Win32" = GetProcAddress(DllHandle,"iParticleAttractionAffectorAffectX")
Rem
bbdoc:
returns:
End Rem
Global iParticleAttractionAffectorAffectY(affector%,affect_y%)"Win32" = GetProcAddress(DllHandle,"iParticleAttractionAffectorAffectY")
Rem
bbdoc:
returns:
End Rem
Global iParticleAttractionAffectorAffectZ(affector%,affect_z%)"Win32" = GetProcAddress(DllHandle,"iParticleAttractionAffectorAffectZ")
Rem
bbdoc:
returns:
End Rem
Global iParticleAttractionAffectorAttract(affector%,attract%)"Win32" = GetProcAddress(DllHandle,"iParticleAttractionAffectorAttract")
Rem
bbdoc:
returns:
End Rem
Global iParticleAttractionAffectorPoint(affector%,x#,y#,z#)"Win32" = GetProcAddress(DllHandle,"iParticleAttractionAffectorPoint")
Rem
bbdoc:
returns:
End Rem
Global iRotationAffectorPivotPoint(affector%,x#,y#,z#)"Win32" = GetProcAddress(DllHandle,"iRotationAffectorPivotPoint")
Rem
bbdoc:
returns:
End Rem
Global iFurthestDistanceOfEffect(affector%,NewDistance#)"Win32" = GetProcAddress(DllHandle,"iFurthestDistanceOfEffect")
Rem
bbdoc:
returns:
End Rem
Global iNearestDistanceOfEffect(affector%,NewDistance#)"Win32" = GetProcAddress(DllHandle,"iNearestDistanceOfEffect")
Rem
bbdoc:
returns:
End Rem
Global iColumnDistanceOfEffect(affector%,NewDistance#)"Win32" = GetProcAddress(DllHandle,"iColumnDistanceOfEffect")
Rem
bbdoc:
returns:
End Rem
Global iCenterOfEffect(affector%,x#,y#,z#)"Win32" = GetProcAddress(DllHandle,"iCenterOfEffect")
Rem
bbdoc:
returns:
End Rem
Global iStrengthOfEffect(affector%,x#,y#,z#)"Win32" = GetProcAddress(DllHandle,"iStrengthOfEffect")


''  BILLBOARDS

Rem
bbdoc:
returns:
End Rem
Global iCreateBillBoardGroup%()"Win32" = GetProcAddress(DllHandle,"iCreateBillBoardGroup")
Rem
bbdoc:
returns:
End Rem
Global iBillBoardToGroup%(group%,sizex#,sizey#,x#,y#,z#,roll#,A%,R%,G%,B%)"Win32" = GetProcAddress(DllHandle,"iBillBoardToGroup")
Rem
bbdoc:
returns:
End Rem
Global iBillBoardByAxisToGroup%(group%,sizex#,sizey#,x#,y#,z#,roll#,A%,R%,G%,B%,axis_x#,axis_y#,axis_z#)"Win32" = GetProcAddress(DllHandle,"iBillBoardByAxisToGroup")
Rem
bbdoc:
returns:
End Rem
Global iFreeBillBoardFromGroup(node%,billboard%)"Win32" = GetProcAddress(DllHandle,"iFreeBillBoardFromGroup")
Rem
bbdoc:
returns:
End Rem
Global iBillBoardGroupShadows(group%,x#,y#,z#,intensity#,ambient#)"Win32" = GetProcAddress(DllHandle,"iBillBoardGroupShadows")
Rem
bbdoc:
returns:
End Rem
Global iBillBoardGroupCount%(group%)"Win32" = GetProcAddress(DllHandle,"iBillBoardGroupCount")
Rem
bbdoc:
returns:
End Rem
Global iBillBoardForceUpdate(group%)"Win32" = GetProcAddress(DllHandle,"iBillBoardForceUpdate")
Rem
bbdoc:
returns:
End Rem
Global iCreateBillBoard%(sizex#,sizey#,x#,y#,z#)"Win32" = GetProcAddress(DllHandle,"iCreateBillBoard")
Rem
bbdoc:
returns:
End Rem
Global iBillBoardColor(node%,topColor%,bottomColor%)"Win32" = GetProcAddress(DllHandle,"iBillBoardColor")
Rem
bbdoc:
returns:
End Rem
Global iBillBoardSize(node%,BillWidth#,BillHeight#)"Win32" = GetProcAddress(DllHandle,"iBillBoardSize")
Rem
bbdoc:
returns:
End Rem
Global iCreateTextBillBoard%(font%,Text$z,sizex#,sizey#,x#,y#,z#,parent%,topRGBA%,bottomRGBA%)"Win32" = GetProcAddress(DllHandle,"iCreateTextBillBoard")


''  ZONE MANAGER

Rem
bbdoc:
returns:
End Rem
Global iCreateZoneMgr%(nearDistance#,farDistance#)"Win32" = GetProcAddress(DllHandle,"iCreateZoneMgr")
Rem
bbdoc:
returns:
End Rem
Global iZoneMgrProperties(zoneNode%,nearDistance#,farDistance#,accumulateChildBoxes%)"Win32" = GetProcAddress(DllHandle,"iZoneMgrProperties")
Rem
bbdoc:
returns:
End Rem
Global iZoneMgrBndBox(zoneNode%,x#,y#,z#,boxWidth#,boxHeight#,boxDepth#)"Win32" = GetProcAddress(DllHandle,"iZoneMgrBndBox")
Rem
bbdoc:
returns:
End Rem
Global iZoneMgrAttachTerrain(zoneNode%,terrain%,structureMapFile$z,colorMapFile$z,detailMapFile$z,ImageX%,ImageY%,sliceSize%)"Win32" = GetProcAddress(DllHandle,"iZoneMgrAttachTerrain")
Rem
bbdoc:
returns:
End Rem
Global iCreateLODMgr%(fadeScale%,useAlpha%,callback%)"Win32" = GetProcAddress(DllHandle,"iCreateLODMgr")
Rem
bbdoc:
returns:
End Rem
Global iLODMesh(node%,distance#,mesh%)"Win32" = GetProcAddress(DllHandle,"iLODMesh")
Rem
bbdoc:
returns:
End Rem
Global iLODMaterialMap(node%,source%,target%)"Win32" = GetProcAddress(DllHandle,"iLODMaterialMap")


''  Bitplanes XEffect Extension

Rem
bbdoc:
returns:
End Rem
Global iXFXStart(vsm%,softShadows%,bitdepth32%)"Win32" = GetProcAddress(DllHandle,"iXFXStart")
Rem
bbdoc:
returns:
End Rem
Global iXFXEnableDepthPass(enable%)"Win32" = GetProcAddress(DllHandle,"iXFXEnableDepthPass")
Rem
bbdoc:
returns:
End Rem
Global iXFXAddPostProcessingFromFile(name$z,effectType%)"Win32" = GetProcAddress(DllHandle,"iXFXAddPostProcessingFromFile")
Rem
bbdoc:
returns:
End Rem
Global iXFXSetPostProcessingUserTexture(texture%)"Win32" = GetProcAddress(DllHandle,"iXFXSetPostProcessingUserTexture")
Rem
bbdoc:
returns:
End Rem
Global iXFXAddShadowToNode(node%,filterType%,shadowType%)"Win32" = GetProcAddress(DllHandle,"iXFXAddShadowToNode")
Rem
bbdoc:
returns:
End Rem
Global iXFXRemoveShadowFromNode(node%)"Win32" = GetProcAddress(DllHandle,"iXFXRemoveShadowFromNode")
Rem
bbdoc:
returns:
End Rem
Global iXFXExcludeNodeFromLightingCalculations(node%)"Win32" = GetProcAddress(DllHandle,"iXFXExcludeNodeFromLightingCalculations")
Rem
bbdoc:
returns:
End Rem
Global iXFXAddNodeToDepthPass(node%)"Win32" = GetProcAddress(DllHandle,"iXFXAddNodeToDepthPass")
Rem
bbdoc:
returns:
End Rem
Global iXFXSetAmbientColor(R%,G%,B%,Alpha%)"Win32" = GetProcAddress(DllHandle,"iXFXSetAmbientColor")
Rem
bbdoc:
returns:
End Rem
Global iXFXSetClearColor(R%,G%,B%,Alpha%)"Win32" = GetProcAddress(DllHandle,"iXFXSetClearColor")
Rem
bbdoc:
returns:
End Rem
Global iXFXAddShadowLight(shadowDimen%,posX#,posY#,posZ#,targetX#,targetY#,targetZ#,R#,G#,B#,Alpha#,lightNearDist#,lightFarDist#,angleDegrees#)"Win32" = GetProcAddress(DllHandle,"iXFXAddShadowLight")
Rem
bbdoc:
returns:
End Rem
Global iXFXSetShadowLightPosition(index%,posX#,posY#,posZ#)"Win32" = GetProcAddress(DllHandle,"iXFXSetShadowLightPosition")
Rem
bbdoc:
returns:
End Rem
Global iXFXGetShadowLightPositionX#(index%)"Win32" = GetProcAddress(DllHandle,"iXFXGetShadowLightPositionX")
Rem
bbdoc:
returns:
End Rem
Global iXFXGetShadowLightPositionY#(index%)"Win32" = GetProcAddress(DllHandle,"iXFXGetShadowLightPositionY")
Rem
bbdoc:
returns:
End Rem
Global iXFXGetShadowLightPositionZ#(index%)"Win32" = GetProcAddress(DllHandle,"iXFXGetShadowLightPositionZ")
Rem
bbdoc:
returns:
End Rem
Global iXFXSetShadowLightTarget(index%,posX#,posY#,posZ#)"Win32" = GetProcAddress(DllHandle,"iXFXSetShadowLightTarget")
Rem
bbdoc:
returns:
End Rem
Global iXEffectsGetShadowLightTarget(index%,posX#,posY#,posZ#)"Win32" = GetProcAddress(DllHandle,"iXEffectsGetShadowLightTarget")
Rem
bbdoc:
returns:
End Rem
Global iXFXGetShadowLightTargetX#(index%)"Win32" = GetProcAddress(DllHandle,"iXFXGetShadowLightTargetX")
Rem
bbdoc:
returns:
End Rem
Global iXFXGetShadowLightTargetY#(index%)"Win32" = GetProcAddress(DllHandle,"iXFXGetShadowLightTargetY")
Rem
bbdoc:
returns:
End Rem
Global iXFXGetShadowLightTargetZ#(index%)"Win32" = GetProcAddress(DllHandle,"iXFXGetShadowLightTargetZ")
Rem
bbdoc:
returns:
End Rem
Global iXFXSetShadowLightColor(index%,R#,G#,B#,Alpha#)"Win32" = GetProcAddress(DllHandle,"iXFXSetShadowLightColor")
Rem
bbdoc:
returns:
End Rem
Global iXFXGetShadowLightColorRed#(index%)"Win32" = GetProcAddress(DllHandle,"iXFXGetShadowLightColorRed")
Rem
bbdoc:
returns:
End Rem
Global iXFXGetShadowLightColorGrn#(index%)"Win32" = GetProcAddress(DllHandle,"iXFXGetShadowLightColorGrn")
Rem
bbdoc:
returns:
End Rem
Global iXFXGetShadowLightColorBlu#(index%)"Win32" = GetProcAddress(DllHandle,"iXFXGetShadowLightColorBlu")
Rem
bbdoc:
returns:
End Rem
Global iXFXGetShadowLightColorAlpha#(index%)"Win32" = GetProcAddress(DllHandle,"iXFXGetShadowLightColorAlpha")


'' GUI

Rem
bbdoc:
returns:
End Rem
Global iGUISetFont(font%)"Win32" = GetProcAddress(DllHandle,"iGUISetFont")
Rem
bbdoc:
returns:
End Rem
Global iGUISetColor(color_element%,r%,g%,b%,alpha%)"Win32" = GetProcAddress(DllHandle,"iGUISetColor")
Rem
bbdoc:
returns:
End Rem
Global iGUIClear()"Win32" = GetProcAddress(DllHandle,"iGUIClear")
Rem
bbdoc:
returns:
End Rem
Global iGUIRemove(gui_element%)"Win32" = GetProcAddress(DllHandle,"iGUIRemove")
Rem
bbdoc:
returns:
End Rem
Global iGUIGetText$z(guie_element%)"Win32" = GetProcAddress(DllHandle,"iGUIGetText")
Rem
bbdoc:
returns:
End Rem
Global iGUISetText(gui_element%,Text$z)"Win32" = GetProcAddress(DllHandle,"iGUISetText")
Rem
bbdoc:
returns:
End Rem
Global iCreateWindow%(title$z,tx%,ty%,bx%,by%,model%,parent%)"Win32" = GetProcAddress(DllHandle,"iCreateWindow")
Rem
bbdoc:
returns:
End Rem
Global iStaticText%(Text$z,TopX%,TopY%,BotX%,BotY%,border%,wordwrap%,parent%)"Win32" = GetProcAddress(DllHandle,"iStaticText")
Rem
bbdoc:
returns:
End Rem
Global iCreateButton%(tx%,ty%,bx%,by%,id%,Text$z,tip$z,parent%)"Win32" = GetProcAddress(DllHandle,"iCreateButton")
Rem
bbdoc:
returns:
End Rem
Global iCreateScrollBar%(horz%,tx%,ty%,bx%,by%,id%,cur_val%,max_val%,parent%)"Win32" = GetProcAddress(DllHandle,"iCreateScrollBar")
Rem
bbdoc:
returns:
End Rem
Global iCreateListBox%(tx%,ty%,bx%,by%,id%,background%,parent%)"Win32" = GetProcAddress(DllHandle,"iCreateListBox")
Rem
bbdoc:
returns:
End Rem
Global iAddGadgetItem(list_box%,Text$z)"Win32" = GetProcAddress(DllHandle,"iAddGadgetItem")
Rem
bbdoc:
returns:
End Rem
Global iInsertGadgetItem(list_box%,Text$z,index%)"Win32" = GetProcAddress(DllHandle,"iInsertGadgetItem")
Rem
bbdoc:
returns:
End Rem
Global iRemoveGadgetItem(list_box%,index%)"Win32" = GetProcAddress(DllHandle,"iRemoveGadgetItem")
Rem
bbdoc:
returns:
End Rem
Global iSelectGadgetItem(list_box%,index%)"Win32" = GetProcAddress(DllHandle,"iSelectGadgetItem")
Rem
bbdoc:
returns:
End Rem
Global iCreateEditBox%(Text$z,tx%,ty%,bx%,by%,id%,border%,password%,parent%)"Win32" = GetProcAddress(DllHandle,"iCreateEditBox")
Rem
bbdoc:
returns:
End Rem
Global iStaticImage%(texture%,x%,y%,useAlpha%,id%,parent%)"Win32" = GetProcAddress(DllHandle,"iStaticImage")
Rem
bbdoc:
returns:
End Rem
Global iCreateCheckBox%(Text$z,tx%,ty%,bx%,by%,id%,checked%,parent%)"Win32" = GetProcAddress(DllHandle,"iCreateCheckBox")
Rem
bbdoc:
returns:
End Rem
Global iCheckCheckBox(checkbox%,checked%)"Win32" = GetProcAddress(DllHandle,"iCheckCheckBox")
Rem
bbdoc:
returns:
End Rem
Global iAddFileOpen%(Text$z,id%,model%,parent%)"Win32" = GetProcAddress(DllHandle,"iAddFileOpen")


''  3D MATH

Rem
bbdoc:
returns:
End Rem
Global iExtrapolatePoint:Float(time#,initpos#,vel#,accel#,maxvel#)"Win32" = GetProcAddress(DllHandle,"iExtrapolatePoint")


''  IRRKLANG SOUND

Rem
bbdoc:
returns:
End Rem
Global iKlangInit%()"Win32" = GetProcAddress(DllHandle,"iKlangInit")
Rem
bbdoc:
returns:
End Rem
Global iKlangUpdate()"Win32" = GetProcAddress(DllHandle,"iKlangUpdate")
Rem
bbdoc:
returns:
End Rem
Global iMasterVolume(volume#)"Win32" = GetProcAddress(DllHandle,"iMasterVolume")
Rem
bbdoc:
returns:
End Rem
Global iPlaySound:Int(file$z,looped%,paused%,track%,mode%,fx%)"Win32" = GetProcAddress(DllHandle,"iPlaySound")
Rem
bbdoc:
returns:
End Rem
Global iPlay3DSound:Int(file$z,x#,y#,z#,looped%,paused%,track%,mode%,fx%)"Win32" = GetProcAddress(DllHandle,"iPlay3DSound")
Rem
bbdoc:
returns:
End Rem
Global iPauseAllSounds(bool%)"Win32" = GetProcAddress(DllHandle,"iPauseAllSounds")
Rem
bbdoc:
returns:
End Rem
Global iStopAllSounds()"Win32" = GetProcAddress(DllHandle,"iStopAllSounds")
Rem
bbdoc:
returns:
End Rem
Global iListenerPosition(x#,y#,z#,lookX#,lookY#,lookZ#,velX#,velY#,velZ#,upX#,upY#,upZ#)"Win32" = GetProcAddress(DllHandle,"iListenerPosition")
Rem
bbdoc:
returns:
End Rem
Global iFreeSound(sound%)"Win32" = GetProcAddress(DllHandle,"iFreeSound")
Rem
bbdoc:
returns:
End Rem
Global iFreeSoundFile(file$z)"Win32" = GetProcAddress(DllHandle,"iFreeSoundFile")
Rem
bbdoc:
returns:
End Rem
Global iFreeAllSoundFiles()"Win32" = GetProcAddress(DllHandle,"iFreeAllSoundFiles")
Rem
bbdoc:
returns:
End Rem
Global iKlangEnd()"Win32" = GetProcAddress(DllHandle,"iKlangEnd")
Rem
bbdoc:
returns:
End Rem
Global iSoundLength%(sound%)"Win32" = GetProcAddress(DllHandle,"iSoundLength")
Rem
bbdoc:
returns:
End Rem
Global iGetPlayPosition%(sound%)"Win32" = GetProcAddress(DllHandle,"iGetPlayPosition")
Rem
bbdoc:
returns:
End Rem
Global iSoundPlaying%(sound%)"Win32" = GetProcAddress(DllHandle,"iSoundPlaying")
Rem
bbdoc:
returns:
End Rem
Global iPauseSound(sound:Int,bool:Int)"Win32" = GetProcAddress(DllHandle,"iPauseSound")
Rem
bbdoc:
returns:
End Rem
Global iPlaySpeed%(sound%,speed#)"Win32" = GetProcAddress(DllHandle,"iPlaySpeed")
Rem
bbdoc:
returns:
End Rem
Global iSetPlayPosition%(sound%,position%)"Win32" = GetProcAddress(DllHandle,"iSetPlayPosition")
Rem
bbdoc:
returns:
End Rem
Global iPositionSound(sound%,x#,y#,z#)"Win32" = GetProcAddress(DllHandle,"iPositionSound")
Rem
bbdoc:
returns:
End Rem
Global iSoundVolume(sound%,volume#)"Win32" = GetProcAddress(DllHandle,"iSoundVolume")
Rem
bbdoc:
returns:
End Rem
Global iSoundDistance(sound%,distance#)"Win32" = GetProcAddress(DllHandle,"iSoundDistance")
Rem
bbdoc:
returns:
End Rem
Global iStopSound(sound%)"Win32" = GetProcAddress(DllHandle,"iStopSound")
Rem
bbdoc:
returns:
End Rem
Global iParentNode(snode%,node%)"Win32" = GetProcAddress(DllHandle,"iParentNode")
Rem
bbdoc:
returns:
End Rem
Global iAddSoundNode%(file$z,min_dist#,loop%,parent%)"Win32" = GetProcAddress(DllHandle,"iAddSoundNode")


Rem
bbdoc:
returns:
End Rem
Function iMakeARGB:Int( alpha%, red%, green%, blue% )
    Return (alpha Shl 24) + (red Shl 16) + (green Shl 8) + blue
End Function




