SceneConst

Inheritance diagram of rumba.SceneConst
class SceneConst

An immutable scene node value.

This value is a scene graph, with at each node, an inherited world matrix, a visibility, an optional geometry, child nodes and arbitrary attributes.

About the visibility.

There is a difference between hidding and deactivating nodes. A SceneGraphNode node generating such Scene values might be deactivated using the inactive tag. In that case, the SceneGraphNode simply does not generate the value. The inactive tag can’t be animated. The exported geometry caches do not include the deactivated nodes.

If the SceneGraphNode is hidden using the show attribute, the Scene value is generated, but with a show attribute at false. The Scene inherited visibility can be queried using the Scene’s traversal. The visibility can be animated. The exported geometry caches include the geometries at every frames, no matter the visibility state.:cvar SceneConst default_value: Static. The default value.

Methods

__init__

Constructor(s)

attribute(attribute)

Return an attribute.

child(path, world_matrix)

Return a child scene node.

geometry()

Get the node geometry.

has_attribute(attribute)

Returns true if this node has the attribute defined on the node.

has_geometry()

Returns true if this node has a geometry.

is_shown()

Returns true if this Scene node is shown.

matrix()

Returns the node transform.

name()

Returns the node name.

read_attributes()

Return a read-only attribute iteration.

read_children(children_only, shapes_only)

Get the scene traversal.

Properties

default_value

__init__()

Constructor(s)

Value (arg1: bool)

Create a boolean value.

Value (arg1: int)

Create an integer value.

Value (arg1: float)

Create a float value.

Value (arg1: double)

Create a double value.

Value (string: unicode)

Create a string value.

Value (string: wchar_t)

Create a string value.

Value (string: unicode)

Create a string value.

Value (string: unicode)

Create a wide string value.

Value (arg1: Imath.V2f)

Create a Imath::V2f value.

Value (arg1: Imath.V3f)

Create a Imath::V3f value.

Value (arg1: Imath.V4f)

Create a Imath::V4f value.

Value (arg1: Imath.V2d)

Create a Imath::V2d value.

Value (arg1: Imath.V3d)

Create a Imath::V3d value.

Value (arg1: Imath.V4d)

Create a Imath::V4d value.

Value (arg1: Imath.V2i)

Create a Imath::V2i value.

Value (arg1: Imath.V3i)

Create a Imath::V3i value.

Value (arg1: Imath.V4i)

Create a Imath::V4i value.

Value (arg1: Imath.Color4f)

Create a Imath::Color4f value.

Value (arg1: Imath.M44f)

Create a Imath::M44f value.

Value (arg1: Imath.M44d)

Create a Imath::M44d value.

Value (arg1: Imath.Box3f)

Create a Imath::Box3f value.

Value (arg1: Imath.Quatf)

Create a Imath::Quatf value.

Value (arg1: Imath.Quatd)

Create a Imath::Quatd value.

Value (user_data: UserData)

Create a user data value.

attribute(attribute: StringView) Value

Return an attribute.

This method returns a node attribute if it exists. Use the iterators to access the inherited attributes.

Return type

Value

Raises

RuntimeError – If the attribute does not exist.

child(path: unicode, world_matrix: Imath.M44d) SceneConst

Return a child scene node.

Parameters
  • path (unicode) – The child path from this node, like “child0/child1/child2”

  • world_matrix (Imath.M44d) – If not null and the child exists, world_matrix is filled with the child’s world matrix

Return type

SceneConst

child(path: unicode,world_matrix: Imath.M44d) -> SceneConst

Return a child scene node.

Parameters
  • path (unicode) – The child path from this node, like “child0/child1/child2”

  • world_matrix (Imath.M44d) – If not null and the child exists, world_matrix is filled with the child’s world matrix

Return type

SceneConst

geometry() Shape

Get the node geometry.

Return type

Shape

has_attribute(attribute: StringView) bool

Returns true if this node has the attribute defined on the node.

This method returns true only if the node itself as attribute. If the attribute is inherited from the parents, it returns false. Use the iterators to access the inherited attributes.

Return type

bool

has_geometry() bool

Returns true if this node has a geometry.

Return type

bool

is_shown() bool

Returns true if this Scene node is shown.

In order to be visible, a node must have its shown attribute and the ones from its parents set to true.

Return type

bool

matrix() Imath.M44d

Returns the node transform.

Return type

Imath.M44d

name() unicode

Returns the node name.

Return type

unicode

read_attributes() Attributes

Return a read-only attribute iteration.

Return type

Attributes

read_children(children_only: bool, shapes_only: bool) Traversal

Get the scene traversal.

Return type

Traversal