osg.Switch¶
-
class
osg.
Switch
¶ Represents: c++ class Wraps: osg::Switch Bases: osg.Group
osg.Switch
is a Group node that allows switching between children. Typical uses would be for objects which might need to be rendered differently at different times, for instance a switch could be used to represent the different states of a traffic light.Constructors:
-
osg.
Switch
()¶
Methods:
-
:
insertChild
(unsigned index, osg.Node node)¶ -
Параметры: - index (
unsigned
) – - node (
osg.Node
) –
Тип результата: bool
- index (
-
:
insertChild
(unsigned index, osg.Node node, bool val) -
Параметры: - index (
unsigned
) – - node (
osg.Node
) – - val (
bool
) –
Тип результата: bool
- index (
-
:
removeChildren
(unsigned pos, unsigned count)¶ -
Параметры: - pos (
unsigned
) – - count (
unsigned
) –
Тип результата: bool
- pos (
-
:
setValue
(unsigned index, bool val)¶ -
Параметры: - index (
unsigned
) – - val (
bool
) –
- index (
-
:
getValue
(unsigned index)¶ -
Параметры: index ( unsigned
) –Тип результата: bool
-
:
setAllChildrenOff
()¶ Set all the children off (
false
), and set the new default child value to off (false
).Тип результата: bool
-
:
setAllChildrenOn
()¶ Set all the children on (
true
), and set the new default child value to on (true
).Тип результата: bool
-
:
setSingleChildOn
(unsigned pos)¶ Set a single child on, switch off all other children.
Параметры: pos ( unsigned
) –Тип результата: bool
-