Module vrNodePtr :: Class vrNodePtr
[frames] | no frames]

Class vrNodePtr

 object --+        
          |        
??.instance --+    
              |    
        NodePtr --+
                  |
                 vrNodePtr

The NodePtr class is python representation of a node within the scenegraph. It can be used to alter the existing structure of it by adding/removing nodes.

Example:

  See also example find.py

The Light functions are deprecated. Use API v2 light types instead, vrdBaseLightNode, vrdPointLightNode etc. For Transform functions, use API v2 vrdTransformNode type.

Instance Methods
 
__init__(source)
The constructor of the vrNodePtr class.
bool
addAttachment(attachment)
Adds an attachment to a node.
 
addChild(node)
Adds a child node to a parent node.
vrNodePtr
clone()
Creates a clone of the node.
vrNodePtr
copy()
Creates a copy of the node.
vrFieldAccess
fields()
Returns access to the fields of the node core.
bool
getActive()
Return render state for this node.
FieldContainerPtr
getAttachment(aname)
Returns the attachment.
string
getAttribute(key)
Gets an attribute of the node.
list of floats (32bit)
getBoundingBox()
Returns the bounding box of the node.
vrNodePtr
getChild(id)
Gets a child node by index in [0, n] or name.
unsigned int (32bit)
getID()
Returns the internal id of the node.
vrMaterialPtr
getMaterial()
Returns the material of a geometry node.
unsigned integer
getNChildren()
Gets the number of children.
string
getName()
Returns the name of the node.
vrNodePtr
getParent()
Returns the parent node.
NodePtr
getPtr()
Return the OpenSG NodePtr.
string
getType()
Return returns the type for this node.
bool
hasAttachment(fname)
Checks the existence of an attachment via name.
boolean
hasAttribute(key)
Looks if an attribute exists.
bool
isAsset()
Checks if the node is an asset from the Asset Manager.
bool
isValid()
Returns true when the node is valid.
 
removeAttribute(key)
Removes an attribute of the node.
 
setActive(state)
Enables/disables rendering for this node.
 
setAttribute(key, value)
Sets an attribute of the node.
 
setMaterial(mat)
Sets the material of a geometry node.
 
setName(name)
Sets the name of the node.
 
setTransparency(t)
Sets the transparency.
 
sub()
Removes the node itself from the scenegraph.
bool
subAttachment(attachment)
Removes an attachment from the node.
 
subChild(node)
Removes a child node from a parent node.

Inherited from NodePtr: __reduce__

Inherited from unreachable.instance: __new__

    Transformation
list of floats (32bit)
getCenter()
Returns the center of the node.
list of floats (32bit)
getLocalTranslation()
Returns the translation of a transform node in local coordinates.
list of floats (32bit)
getRotation()
Returns the rotation of a transform node.
list of floats (32bit)
getScale()
Returns the scale of a transform node.
list of floats (32bit)
getTranslation()
Returns the translation of a transform node in local coordinates.
list of floats (32bit)
getWorldRotation()
Returns the world rotation (all transformation above this node accumulated to the top).
list of floats (32bit)
getWorldScale()
Returns the world scale (all transformation above this node accumulated to the top).
list of floats (32bit)
getWorldTransform()
Returns the world transform (all transformation above this node accumulated to the top).
list of floats (32bit)
getWorldTranslation()
Returns the world translation (all transformation above this node accumulated to the top).
bool
isTransform()
Returns true if node is a transform node.
 
makeComponentTransform()
Converts the node into a component transform node.
 
makeTransform(search)
Converts the node into a transform node.
 
setAxisRotation(axis, ax, ay, az, bx, by, bz, alpha)
Rotates a transform node around an arbitrary axis.
 
setLocalTranslation(x, y, z)
Sets the translation of a transform node in local coordinates.
 
setRotation(x, y, z)
Sets the rotation of a transform node.
 
setScale(x, y, z)
Sets the scale of a transform node.
 
setTransformMatrix(matrix, transposed)
Sets the matrix of a matrix transform node.
 
setTranslation(x, y, z)
Sets the translation of a transform node in local coordinates.
 
setWorldTranslation(x, y, z)
Sets the translation of a transform node in world coordinates.
    Geometry
bool
getDlistCache()
Returns display list cache state, for vertices animation you should disable it!
list of floats (32bit)
getNormals()
Returns the normals of a geometry node.
list of floats (32bit)
getPositions()
Returns the vertices of a geometry node.
list of floats (32bit)
getTexCoords()
Returns the texture coordinates of a geometry node.
bool
getVBO()
Returns vbo rendering state.
 
setDlistCache(state)
Enabled or disables the display list cache, for vertices animation you should disable it!
 
setNormals(normals)
Sets the normals of a geometry node.
 
setPositions(positions)
Sets the vertices of a geometry node.
 
setTexCoords(texCoords)
Sets the texture coordinates of a geometry node.
 
setVBO(state)
Enables or disables the vbo rendering.
    Light
 
changeLightType(type)
If the node is a light node, converts the light source to another light source type.
 
deleteRayFile()
If the node is a ray file light node, deletes the ray file of the ray file light.
int
getAreaLightInteractiveQuality()
For an area light node, return the interactive area light sampling quality level for Raytracing.
bool
getAreaLightPrimaryVisibility()
For an area light node, return whether the area light is visible for primary rays in Raytracing.
int
getAreaLightStillFrameQuality()
For an area light node, return the still frame area light sampling quality level for Raytracing.
bool
getAreaLightUseConeAngle()
For a disk or rectangular area light node, return whether the light uses spotlight angles to define its emission.
bool
getAreaLightVisibleInReflections()
For an area light node, return whether the area light is visible in reflections in Raytracing.
bool
getCastShadowOnShadowMaterial()
For a light node, return whether the light casts a shadow on the shadow material or not.
list of 3 floats (32bit)
getDiffuseLightColor()
If the node is a light node, returns the diffuse color of the light as RGB.
list of 3 floats (32bit)
getGlossyLightColor()
If the node is a light node, returns the glossy color of a light as RGB.
float
getGroundShadowIntensity()
For a light node, return the ground shadow intensity of the light.
bool
getIlluminateShadowMaterial()
For a light node, return whether the light illuminates the shadow material or not.
float
getLightConeAngle()
For a spot, disk or rectangular light node, return the cone angle of the light.
float
getLightImportanceMultiplier()
For a light node, return the importance multiplier of the light.
float
getLightIntensity()
For a light node, return the intensity of the light.
float
getLightPenumbraAngle()
For a spot, disk or rectangular light node, return the penumbra angle of the light.
int
getLightTemperature()
For a light node, return the temperature used to determine the light color in kelvin.
float
getLightVisualizationScale()
For a light node, return the scale of the light source visualization geometry.
bool
getLightVisualizationVisible()
For a light node, return whether the light source visualization is visible.
bool
getRayFileUsePhotonsForDirectLighting()
For a rayfile light node, return whether the rayfile light uses photons for direct lighting or a surface with raylight evaluation.
bool
getRayFileUseRandomSampling()
For a rayfile light node, return whether the rayfile light uses random sampling for the rays.
unsigned int
getRayFileVisualizationRayCount()
For a rayfile light node, return the number of ray file rays that are visualized in the viewport.
float
getRayFileVisualizationRayLength()
For a rayfile light node, return the length of the ray file rays that are visualized in the viewport.
float
getShadowIntensity()
For a light node, return the shadow intensity of the light.
float
getShadowMapFilterRadius()
For a light node, return the radius for shadow map filtering in OpenGL.
int
getShadowMapResolution()
For a light node, return the resolution of the shadow map used in OpenGL.
bool
getUseIESProfile()
For a light node, return whether the light source uses a IES profile.
bool
getUseLightTemperature()
For a light node, return whether the light uses the temperature value to determine its color.
bool
isAreaLight()
Return whether the node is an area light node.
bool
isDirectionalLight()
Return whether the node is a directional light node.
bool
isDiskLight()
Return whether the node is a disk light node.
bool
isLight()
Checks if the node is a light source node.
bool
isLightOn()
For a light node, return whether the light is on.
bool
isLocalLight()
For a light node, return whether the light is a local light whose illumination is limited to the objects defined in a light link set.
bool
isPointLight()
Return whether the node is a point light node.
bool
isRayFileLight()
Return whether the node is a rayfile light node.
bool
isRectangularLight()
Return whether the node is a rectangular light node.
bool
isSphericalLight()
Return whether the node is a spherical light node.
bool
isSpotLight()
Return whether the node is a spot light node.
 
loadIESProfile(filename)
If the node is a light node, loads a IES file.
 
loadRayFile(filename)
If the node is a ray file light node, loads a ray file to be used by the light.
 
setAreaLightInteractiveQuality(quality)
If the node is an area light node, sets the interactive area light sampling quality level for Raytracing.
 
setAreaLightPrimaryVisibility(state)
If the node is an area light node, sets whether the area light is visible for primary rays in Raytracing.
 
setAreaLightStillFrameQuality(quality)
If the node is an area light node, sets the still frame area light sampling quality level for Raytracing.
 
setAreaLightUseConeAngle(state)
If the node is a disk or rectangular area light node, sets whether the light uses spotlight angles to define its emission.
 
setAreaLightVisibleInReflections(state)
If the node is an area light node, sets whether the area light is visible in reflections in Raytracing.
 
setCastShadowOnShadowMaterial(state)
If the node is a light node, sets whether the light casts a shadow on the shadow material or not.
 
setDiffuseLightColor(r, g, b)
If the node is a light node, sets the diffuse color of the light as RGB.
 
setGlossyLightColor(r, g, b)
If the node is a light node, sets the glossy color of the light as RGB.
 
setGroundShadowIntensity(value)
If the node is a light node, sets the ground shadow intensity of the light.
 
setIlluminateShadowMaterial(state)
If the node is a light node, sets whether the light illuminates the shadow material or not.
 
setLightConeAngle(value)
If the node is a spot, disk or rectangular light node that uses spot angles for emission, sets the cone angle of the light.
 
setLightImportanceMultiplier(value)
If the node is a light node, sets the importance multiplier for the light.
 
setLightIntensity(value)
If the node is a light node, sets the intensity of the light.
 
setLightOn(state)
If the node is a light node, switches the light source on or off.
 
setLightPenumbraAngle(value)
If the node is a spot, disk or rectangular light node that uses spot angles for emission, sets the penumbra angle of the light.
 
setLightTemperature(kelvin)
If the node is a light node, sets the temperature used to determine the light color in kelvin (default: 6504).
 
setLightVisualizationScale(scale)
If the node is a light node, sets the scale of the light source visualization geometry.
 
setLightVisualizationVisible(state)
If the node is a light node, sets whether the light source visualization is visible.
 
setLocalLight(state)
If the node is a light node, sets the light to local or global lighting.
 
setRayFileUsePhotonsForDirectLighting(state)
If the node is a ray file light node, sets whether the rayfile light uses photons for direct lighting or a surface with raylight evaluation.
 
setRayFileUseRandomSampling(state)
If the node is a ray file light node, sets whether the rayfile light uses random sampling for the rays.
 
setRayFileVisualizationRayCount(count)
If the node is a ray file light node, sets the number of ray file rays that are visualized in the viewport.
 
setRayFileVisualizationRayLength(length)
If the node is a ray file light node, sets the length of the ray file rays that are visualized in the viewport..
 
setShadowIntensity(value)
If the node is a light node, sets the shadow intensity of the light.
 
setShadowMapFilterRadius(radius)
If the node is a light node, sets the radius for shadow map filtering in OpenGL.
 
setShadowMapResolution(resolution)
If the node is a light node, sets the resolution of the shadow map used in OpenGL (default: 1024).
 
setUseIESProfile(state)
If the node is a light node, enables the IES profile for the light.
 
setUseLightTemperature(state)
If the node is a light node, sets whether the light uses the temperature value to determine its color.
 
toggleLight()
If the node is a light node, toggles the light source on or off depending on its previous state.
    Deprecated
 
setFieldBool()
Obsolete, please use the field access API (vrFieldAccess) instead.
 
setFieldColor4f()
Obsolete, please use the field access API (vrFieldAccess) instead.
 
setFieldInt16()
Obsolete, please use the field access API (vrFieldAccess) instead.
 
setFieldInt32()
Obsolete, please use the field access API (vrFieldAccess) instead.
 
setFieldNode()
Obsolete, please use the field access API (vrFieldAccess) instead.
 
setFieldPnt2f()
Obsolete, please use the field access API (vrFieldAccess) instead.
 
setFieldPnt3f()
Obsolete, please use the field access API (vrFieldAccess) instead.
 
setFieldReal32()
Obsolete, please use the field access API (vrFieldAccess) instead.
 
setFieldReal64()
Obsolete, please use the field access API (vrFieldAccess) instead.
 
setFieldString()
Obsolete, please use the field access API (vrFieldAccess) instead.
 
setFieldUInt16()
Obsolete, please use the field access API (vrFieldAccess) instead.
 
setFieldUInt32()
Obsolete, please use the field access API (vrFieldAccess) instead.
 
setFieldVec2f()
Obsolete, please use the field access API (vrFieldAccess) instead.
 
setFieldVec3f()
Obsolete, please use the field access API (vrFieldAccess) instead.
 
setFieldVec4f()
Obsolete, please use the field access API (vrFieldAccess) instead.
Static Methods
 
removeAssetManagerReference(...)
For every node that is an asset, removes its reference to the Asset Manager.
Class Variables
  __instance_size__ = 72
Method Details

__init__(source)
(Constructor)

 

The constructor of the vrNodePtr class. There are three valid versions:

vrNodePtr() Creates a vrNodePtr object.

vrNodePtr(source) Creates a vrNodePtr object from an unsigned int.

vrNodePtr(source) Creates a vrNodePtr object from a NodePtr.

Parameters:
  • source (unsigned int or NodePtr) - The source (Optional).
Overrides: NodePtr.__init__

addAttachment(attachment)

 

Adds an attachment to a node.

Parameters:
  • attachment (FieldContainerPtr) - The attachment to add.
Returns: bool
Success (true or false).

addChild(node)

 

Adds a child node to a parent node.

Parameters:
  • node (vrNodePtr) - The child node.

changeLightType(type)

 

If the node is a light node, converts the light source to another light source type.

Supported types are: UDirectionalLight, USpotLight, UPointLight, UDiskLight, URectangularLight, USphericalLight, URayLight.

Parameters:
  • type (string) - The new type of the light.

clone()

 

Creates a clone of the node.

Returns: vrNodePtr
The clone.

copy()

 

Creates a copy of the node.

Returns: vrNodePtr
The copy.

fields()

 

Returns access to the fields of the node core. Necessary to alter/query the fields.

Returns: vrFieldAccess
The field access object.

getActive()

 

Return render state for this node.

Returns: bool
The render state: On/Off.

getAreaLightInteractiveQuality()

 

For an area light node, return the interactive area light sampling quality level for Raytracing.

Supported light types: area lights (Disk light, Rectangular light, Spherical light).

Returns: int
The quality level.

getAreaLightPrimaryVisibility()

 

For an area light node, return whether the area light is visible for primary rays in Raytracing.

Supported light types: area lights (Disk light, Rectangular light, Spherical light).

Returns: bool
True if the area light is visible for primary rays in Raytracing.

getAreaLightStillFrameQuality()

 

For an area light node, return the still frame area light sampling quality level for Raytracing.

Supported light types: area lights (Disk light, Rectangular light, Spherical light).

Returns: int
The quality level.

getAreaLightUseConeAngle()

 

For a disk or rectangular area light node, return whether the light uses spotlight angles to define its emission.

Supported light types: Disk light, Rectangular light.

Returns: bool
Use spotlight angles (true), Lambert emitter (false).

getAreaLightVisibleInReflections()

 

For an area light node, return whether the area light is visible in reflections in Raytracing.

Supported light types: area lights (Disk light, Rectangular light, Spherical light).

Returns: bool
True if the area light is visible in reflections in Raytracing.

getAttachment(aname)

 

Returns the attachment.

Parameters:
  • aname (string) - The name of the attachment.
Returns: FieldContainerPtr
The value.

getAttribute(key)

 

Gets an attribute of the node.

Parameters:
  • key (string) - key.
Returns: string
value.

getBoundingBox()

 

Returns the bounding box of the node.

Returns: list of floats (32bit)
Six floats: The first 3 floats contain the minimum coordinates, the next 3 the maximum coordinates.

getCastShadowOnShadowMaterial()

 

For a light node, return whether the light casts a shadow on the shadow material or not.

Returns: bool
True if the light casts a shadow on the shadow material.

getCenter()

 

Returns the center of the node.

Returns: list of floats (32bit)
Three floats: the x, y and z coordinate.

getChild(id)

 

Gets a child node by index in [0, n] or name.

Parameters:
  • id (unsigned integer or string) - The index or the name of the child node.
Returns: vrNodePtr
The child node.

getDiffuseLightColor()

 

If the node is a light node, returns the diffuse color of the light as RGB.

Returns: list of 3 floats (32bit)
The RGB color.

getDlistCache()

 

Returns display list cache state, for vertices animation you should disable it!

Returns: bool
The display list cache state: On/Off.

getGlossyLightColor()

 

If the node is a light node, returns the glossy color of a light as RGB.

Returns: list of 3 floats (32bit)
The RGB color.

getGroundShadowIntensity()

 

For a light node, return the ground shadow intensity of the light.

Returns: float
The shadow intensity of the light.

getID()

 

Returns the internal id of the node.

Returns: unsigned int (32bit)
The node id.

getIlluminateShadowMaterial()

 

For a light node, return whether the light illuminates the shadow material or not.

Returns: bool
True if the light illuminates the shadow material.

getLightConeAngle()

 

For a spot, disk or rectangular light node, return the cone angle of the light.

The angle is measured from the axis of the cone to the edge.

Returns: float
The cone angle in degrees.

getLightImportanceMultiplier()

 

For a light node, return the importance multiplier of the light.

Returns: float
The importance multiplier.

getLightIntensity()

 

For a light node, return the intensity of the light.

Returns: float
The intensity.

getLightPenumbraAngle()

 

For a spot, disk or rectangular light node, return the penumbra angle of the light.

Returns: float
The penumbra angle in degrees.

getLightTemperature()

 

For a light node, return the temperature used to determine the light color in kelvin.

Returns: int
The temperature in kelvin.

getLightVisualizationScale()

 

For a light node, return the scale of the light source visualization geometry.

Supported light types: delta lights (Directional light, Point light, Spot light).

Returns: float
The visualization scale factor.

getLightVisualizationVisible()

 

For a light node, return whether the light source visualization is visible.

Returns: bool
visible(true), invisible(false).

getLocalTranslation()

 

Returns the translation of a transform node in local coordinates.

Returns: list of floats (32bit)
Three floats: the x, y and z coordinate.

getMaterial()

 

Returns the material of a geometry node.

Returns: vrMaterialPtr
The material.

getNChildren()

 

Gets the number of children.

Returns: unsigned integer
The number of children.

getName()

 

Returns the name of the node.

Returns: string
The name of the node.

getNormals()

 

Returns the normals of a geometry node.

Returns: list of floats (32bit)
N vectors containing three floats each: the x, y and z coordinate.

getParent()

 

Returns the parent node.

Returns: vrNodePtr
The parent node.

getPositions()

 

Returns the vertices of a geometry node.

Returns: list of floats (32bit)
N vectors containing three floats each: the x, y and z coordinate.

getPtr()

 

Return the OpenSG NodePtr.

Returns: NodePtr
The pointer to the node.

getRayFileUsePhotonsForDirectLighting()

 

For a rayfile light node, return whether the rayfile light uses photons for direct lighting or a surface with raylight evaluation.

Supported light type: Rayfile light.

Returns: bool
True if the rayfile light uses photons for direct lighting.

getRayFileUseRandomSampling()

 

For a rayfile light node, return whether the rayfile light uses random sampling for the rays.

Returns: bool
True if the rayfile light uses random sampling.

getRayFileVisualizationRayCount()

 

For a rayfile light node, return the number of ray file rays that are visualized in the viewport.

Supported light type: Rayfile light.

Returns: unsigned int
number of visualized rays

getRayFileVisualizationRayLength()

 

For a rayfile light node, return the length of the ray file rays that are visualized in the viewport.

Returns: float
length of visualized rays

getRotation()

 

Returns the rotation of a transform node.

Returns: list of floats (32bit)
Three floats: the x, y and z coordinate.

getScale()

 

Returns the scale of a transform node.

Returns: list of floats (32bit)
Three floats: the x, y and z coordinate.

getShadowIntensity()

 

For a light node, return the shadow intensity of the light.

Returns: float
The shadow intensity of the light.

getShadowMapFilterRadius()

 

For a light node, return the radius for shadow map filtering in OpenGL.

Supported light types: Spot light, directional light.

Returns: float
The radius for shadow map filtering in OpenGL.

getShadowMapResolution()

 

For a light node, return the resolution of the shadow map used in OpenGL.

Supported light types: Spot light, directional light.

Returns: int
The resolution of the shadow map used in OpenGL.

getTexCoords()

 

Returns the texture coordinates of a geometry node.

Returns: list of floats (32bit)
N vectors containing two floats each: the x and y coordinate.

getTranslation()

 

Returns the translation of a transform node in local coordinates.

Returns: list of floats (32bit)
Three floats: the x, y and z coordinate.

getType()

 

Return returns the type for this node.

Returns: string
The type.

getUseIESProfile()

 

For a light node, return whether the light source uses a IES profile.

Supported types are: Spot light, Point light, Disk light, Rectangular light, Spherical light.

Returns: bool
True if the light uses a IES profile.

getUseLightTemperature()

 

For a light node, return whether the light uses the temperature value to determine its color.

Returns: bool
True if uses the temperature value to determine its color, false otherwise.

getVBO()

 

Returns vbo rendering state.

Returns: bool
The vbo rendering state: On/Off.

getWorldRotation()

 

Returns the world rotation (all transformation above this node accumulated to the top).

Returns: list of floats (32bit)
Three floats: the x, y and z coordinate.

getWorldScale()

 

Returns the world scale (all transformation above this node accumulated to the top).

Returns: list of floats (32bit)
Three floats: the x, y and z coordinate.

getWorldTransform()

 

Returns the world transform (all transformation above this node accumulated to the top).

Returns: list of floats (32bit)
The 4 x 4 matrix consisting of 16 floats.

getWorldTranslation()

 

Returns the world translation (all transformation above this node accumulated to the top).

Returns: list of floats (32bit)
Three floats: the x, y and z coordinate.

hasAttachment(fname)

 

Checks the existence of an attachment via name.

Parameters:
  • fname (string) - The name of the attachment.
Returns: bool
The existence (true or false).

hasAttribute(key)

 

Looks if an attribute exists.

Parameters:
  • key (string) - key.
Returns: boolean
true or false.

isAreaLight()

 

Return whether the node is an area light node.

Returns: bool
True if node is an area light node, false otherwise.

isAsset()

 

Checks if the node is an asset from the Asset Manager.

Returns: bool
True if the node is an asset, false otherwise.

isDirectionalLight()

 

Return whether the node is a directional light node.

Returns: bool
True if node is a directional light node, false otherwise.

isDiskLight()

 

Return whether the node is a disk light node.

Returns: bool
True if node is a disk light node, false otherwise.

isLight()

 

Checks if the node is a light source node.

Returns: bool
True if the node is a light source node, false otherwise.

isLightOn()

 

For a light node, return whether the light is on.

Returns: bool
On (true), off (false).

isLocalLight()

 

For a light node, return whether the light is a local light whose illumination is limited to the objects defined in a light link set.

Returns: bool
True if the light is local, false if it is global and illuminating the whole scene.

isPointLight()

 

Return whether the node is a point light node.

Returns: bool
True if node is a point light node, false otherwise.

isRayFileLight()

 

Return whether the node is a rayfile light node.

Returns: bool
True if node is a rayfile light node, false otherwise.

isRectangularLight()

 

Return whether the node is a rectangular light node.

Returns: bool
True if node is a rectangular light node, false otherwise.

isSphericalLight()

 

Return whether the node is a spherical light node.

Returns: bool
True if node is a spherical light node, false otherwise.

isSpotLight()

 

Return whether the node is a spot light node.

Returns: bool
True if node is a spot light node, false otherwise.

isTransform()

 

Returns true if node is a transform node.

Returns: bool
True if node is a transform node, false otherwise.

isValid()

 

Returns true when the node is valid. Should be called for sanity reasons after searching a node with findNode.

Returns: bool
True if valid, false otherwise.

loadIESProfile(filename)

 

If the node is a light node, loads a IES file.

Supported light source types are: Spot light, Point light, Disk light, Rectangular light, Spherical light.

Parameters:
  • filename (string) - Path to the IES file.

loadRayFile(filename)

 

If the node is a ray file light node, loads a ray file to be used by the light.

Parameters:
  • filename (string) - Path to the ray file.

makeTransform(search)

 

Converts the node into a transform node.

also available:

  • makeTransform()
Parameters:
  • search (boolean) - When true tries to find a transform node parent/child (Optional).

removeAssetManagerReference(...)
Static Method

 

For every node that is an asset, removes its reference to the Asset Manager. The node will also be unshared from other occurrences of that asset.

The Scenegraph UI is updated afterwards.

Parameters:
  • nodes (list of vrNodePtrs) - The list of nodes.

removeAttribute(key)

 

Removes an attribute of the node.

Parameters:
  • key (string) - key.

setActive(state)

 

Enables/disables rendering for this node.

Parameters:
  • state (bool) - Set true to enable and false to disable object.

setAreaLightInteractiveQuality(quality)

 

If the node is an area light node, sets the interactive area light sampling quality level for Raytracing.

Supported light types: area lights (Disk light, Rectangular light, Spherical light).

Parameters:
  • quality (int) - The quality level in [0,8].

setAreaLightPrimaryVisibility(state)

 

If the node is an area light node, sets whether the area light is visible for primary rays in Raytracing.

Supported light types: area lights (Disk light, Rectangular light, Spherical light).

Parameters:
  • state (bool) - Visible (true), invisible (false).

setAreaLightStillFrameQuality(quality)

 

If the node is an area light node, sets the still frame area light sampling quality level for Raytracing.

Supported light types: area lights (Disk light, Rectangular light, Spherical light).

Parameters:
  • quality (int) - The quality level in [0,8].

setAreaLightUseConeAngle(state)

 

If the node is a disk or rectangular area light node, sets whether the light uses spotlight angles to define its emission.

Supported light types: Disk light, Rectangular light.

Parameters:
  • state (bool) - Use spotlight angles (true), Lambert emitter (false).

setAreaLightVisibleInReflections(state)

 

If the node is an area light node, sets whether the area light is visible in reflections in Raytracing.

Supported light types: area lights (Disk light, Rectangular light, Spherical light).

Parameters:
  • state (bool) - Visible (true), invisible (false).

setAttribute(key, value)

 

Sets an attribute of the node.

Parameters:
  • key (string) - key.
  • value (string) - value.

setAxisRotation(axis, ax, ay, az, bx, by, bz, alpha)

 

Rotates a transform node around an arbitrary axis. Two sets of parameters are valid:

setAxisRotation(ax,ay,az,bx,by,bz,alpha) or

setAxisRotation(axis,alpha)

Parameters:
  • axis (vrNodePtr) - The node of the axis.
  • ax (float (32bit)) - The x coordinate of the first axis point.
  • ay (float (32bit)) - The y coordinate of the first axis point.
  • az (float (32bit)) - The z coordinate of the first axis point.
  • bx (float (32bit)) - The x coordinate of the second axis point.
  • by (float (32bit)) - The y coordinate of the second axis point.
  • bz (float (32bit)) - The z coordinate of the second axis point.
  • alpha (float (32bit)) - The angle in degrees.

setCastShadowOnShadowMaterial(state)

 

If the node is a light node, sets whether the light casts a shadow on the shadow material or not.

Parameters:
  • state (bool) - On/off.

setDiffuseLightColor(r, g, b)

 

If the node is a light node, sets the diffuse color of the light as RGB.

Parameters:
  • r (float (32bit)) - red
  • g (float (32bit)) - green
  • b (float (32bit)) - blue

setDlistCache(state)

 

Enabled or disables the display list cache, for vertices animation you should disable it!

Parameters:
  • state (bool) - The display list cache state: On/Off.

setGlossyLightColor(r, g, b)

 

If the node is a light node, sets the glossy color of the light as RGB.

Parameters:
  • r (float (32bit)) - red
  • g (float (32bit)) - green
  • b (float (32bit)) - blue

setGroundShadowIntensity(value)

 

If the node is a light node, sets the ground shadow intensity of the light.

Parameters:
  • value (float) - Shadow intensity (0 means no shadow, 1 means full shadow).

setIlluminateShadowMaterial(state)

 

If the node is a light node, sets whether the light illuminates the shadow material or not.

Parameters:
  • state (bool) - On/off.

setLightConeAngle(value)

 

If the node is a spot, disk or rectangular light node that uses spot angles for emission, sets the cone angle of the light.

Parameters:
  • value (float) - Cone angle in degrees in [0.01..89.99].

setLightImportanceMultiplier(value)

 

If the node is a light node, sets the importance multiplier for the light.

A value higher than 1 increases the probability that the light source emits photons.

Parameters:
  • value (float) - Importance multiplier.

setLightIntensity(value)

 

If the node is a light node, sets the intensity of the light.

Parameters:
  • value (float) - Intensity.

setLightOn(state)

 

If the node is a light node, switches the light source on or off.

Parameters:
  • state (bool) - On (true), off (false).

setLightPenumbraAngle(value)

 

If the node is a spot, disk or rectangular light node that uses spot angles for emission, sets the penumbra angle of the light.

Parameters:
  • value (float) - Penumbra angle in degrees.

setLightTemperature(kelvin)

 

If the node is a light node, sets the temperature used to determine the light color in kelvin (default: 6504).

This setting only has an effect if 'use temperature' is enabled.

Parameters:
  • kelvin (int) - temperature.

setLightVisualizationScale(scale)

 

If the node is a light node, sets the scale of the light source visualization geometry.

Supported light types: delta lights (Directional light, Point light, Spot light).

Parameters:
  • scale (float) - The scale factor.

setLightVisualizationVisible(state)

 

If the node is a light node, sets whether the light source visualization is visible.

Parameters:
  • state (bool) - visible(true), invisible(false).

setLocalLight(state)

 

If the node is a light node, sets the light to local or global lighting.

Parameters:
  • state (bool) - Local (true), global (false).

setLocalTranslation(x, y, z)

 

Sets the translation of a transform node in local coordinates.

Parameters:
  • x (float (32bit)) - The x translation.
  • y (float (32bit)) - The y translation.
  • z (float (32bit)) - The z translation.

setMaterial(mat)

 

Sets the material of a geometry node.

Parameters:
  • mat (vrMaterialPtr) - The material.

setName(name)

 

Sets the name of the node.

Parameters:
  • name (string) - The new name of the node.

setNormals(normals)

 

Sets the normals of a geometry node.

Parameters:
  • normals (list of floats (32bit)) - N vectors containing three floats each: the x, y and z coordinate.

setPositions(positions)

 

Sets the vertices of a geometry node.

Parameters:
  • positions (list of floats (32bit)) - N vectors containing three floats each: the x, y and z coordinate.

setRayFileUsePhotonsForDirectLighting(state)

 

If the node is a ray file light node, sets whether the rayfile light uses photons for direct lighting or a surface with raylight evaluation.

Parameters:
  • state (bool) - On/off.

setRayFileUseRandomSampling(state)

 

If the node is a ray file light node, sets whether the rayfile light uses random sampling for the rays.

Parameters:
  • state (bool) - On/off.

setRayFileVisualizationRayCount(count)

 

If the node is a ray file light node, sets the number of ray file rays that are visualized in the viewport.

Parameters:
  • count (unsigned int) - number of visualized rays

setRayFileVisualizationRayLength(length)

 

If the node is a ray file light node, sets the length of the ray file rays that are visualized in the viewport..

Parameters:
  • length (float) - length of visualized rays

setRotation(x, y, z)

 

Sets the rotation of a transform node.

Parameters:
  • x (float (32bit)) - The x rotation.
  • y (float (32bit)) - The y rotation.
  • z (float (32bit)) - The z rotation.

setScale(x, y, z)

 

Sets the scale of a transform node.

Parameters:
  • x (float (32bit)) - The x scale.
  • y (float (32bit)) - The y scale.
  • z (float (32bit)) - The z scale.

setShadowIntensity(value)

 

If the node is a light node, sets the shadow intensity of the light.

Parameters:
  • value (float) - Shadow intensity (0 means no shadow, 1 means full shadow).

setShadowMapFilterRadius(radius)

 

If the node is a light node, sets the radius for shadow map filtering in OpenGL.

Supported light types: Spot light, directional light.

Parameters:
  • radius (float) - Filter radius in [0,10].

setShadowMapResolution(resolution)

 

If the node is a light node, sets the resolution of the shadow map used in OpenGL (default: 1024).

Supported light types: Spot light, directional light.

Parameters:
  • resolution (int) - Texture resolution.

setTexCoords(texCoords)

 

Sets the texture coordinates of a geometry node.

Parameters:
  • texCoords (list of floats (32bit)) - N vectors containing two floats each: the x and y coordinate.

setTransformMatrix(matrix, transposed)

 

Sets the matrix of a matrix transform node. Note that standard group transform nodes will recalculate their matrix based on their attributes and therefore the matrix will be lost on every update.

Parameters:
  • matrix (list of floats (32bit)) - The 4 x 4 matrix consisting of 16 floats.
  • transposed (bool) - Transposed/not transposed.

setTranslation(x, y, z)

 

Sets the translation of a transform node in local coordinates.

Parameters:
  • x (float (32bit)) - The x translation.
  • y (float (32bit)) - The y translation.
  • z (float (32bit)) - The z translation.

setTransparency(t)

 

Sets the transparency.

Parameters:
  • t (float) - The transparency.

setUseIESProfile(state)

 

If the node is a light node, enables the IES profile for the light.

Supported types are: Spot light, Point light, Disk light, Rectangular light, Spherical light.

Parameters:
  • state (bool) - On/off.

setUseLightTemperature(state)

 

If the node is a light node, sets whether the light uses the temperature value to determine its color.

Parameters:
  • state (bool) - Use temperature on/off.

setVBO(state)

 

Enables or disables the vbo rendering.

Parameters:
  • state (bool) - The vbo rendering state: On/Off.

setWorldTranslation(x, y, z)

 

Sets the translation of a transform node in world coordinates.

Parameters:
  • x (float (32bit)) - The x translation.
  • y (float (32bit)) - The y translation.
  • z (float (32bit)) - The z translation.

subAttachment(attachment)

 

Removes an attachment from the node.

Parameters:
  • attachment (FieldContainerPtr) - The attachment to remove.
Returns: bool
Success (true or false).

subChild(node)

 

Removes a child node from a parent node.

Parameters:
  • node (vrNodePtr) - The child node.