This is preliminary documentation and is subject to change.

WebGL 3D Space

3d Space, list of nodes, materials, textures and 3d properties.


Constructor creates new 3d space object. Usually space created from iv.window.

wnd 3d window
gl WebGL context.



root Root 3d node
gl WebGL context
window 3d window
view default view
root Root 3d node
materials Array of materials
cfgTextures true if textures are allowed
cfgDbl double sided rendering
cfgKeepMeshData &1 - keep faces, &2 - keep points
cfgDefMtl Default material. If null, per node materials will be used.
cfgSelZOffset If true, selected objects will have z offset
cfgRMode Default render mode. 0 is idefault value.
stdLights Array of lights. If set, this lights will override lights in scene.




Method selects node in 3d space.

node Node to select.
sel true to select node, false - deselect.
keep Keep old selection. In false previous selection will be removed.


Method selects range of nodes in 3d space. Method is used with tree-view control, when user selects nodes with shift key.

a First node
b Second node

Node which was firstly created in its parent object is first in the list. Same as in tree-view control. This method does not send notifications.


Method return list of selected nodes. If selection is empty null will be returned.

Select None:,false,true);




Method creates new material


If string - this will be name of material. You should create material channels after that.

If object - data for material properties. This data may include name, colors, blending, textures, etc.
For description of material please see WebGL material.


This method searches material by name and returns it.

name Name of material.

If material was found it will be returned. If such material was not found, null will be returned.


Method marks viewport as invalid and scheduled update for the next frame. This method invokes iv.window.invalidate


[optional] may be undefined or bit combinations of:

iv.INV_VERSION Update camera, increment current camera version. Version may be used by billboards in order to update position only when required.
iv.INV_STRUCTURE Structure was changed. Used to update shadow maps.
iv.INV_MTLS Flush shaders in materials. Same as

Default is 0.


Method removes all shaders from materials. Method may be used after some changes in scenes, for instance after chaning lights.


Used internally for rendering scene.


Rest methods are used internally.

In this article