Panda3D
Loading...
Searching...
No Matches
selectiveChildNode.I
Go to the documentation of this file.
1/**
2 * PANDA 3D SOFTWARE
3 * Copyright (c) Carnegie Mellon University. All rights reserved.
4 *
5 * All use of this software is subject to the terms of the revised BSD
6 * license. You should have received a copy of this license along
7 * with this source code in a file named "LICENSE."
8 *
9 * @file selectiveChildNode.I
10 * @author drose
11 * @date 2002-03-06
12 */
13
14/**
15 *
16 */
17INLINE SelectiveChildNode::
18SelectiveChildNode(const std::string &name) :
19 PandaNode(name),
20 _selected_child(0)
21{
22}
23
24/**
25 *
26 */
27INLINE SelectiveChildNode::
28SelectiveChildNode(const SelectiveChildNode &copy) :
29 PandaNode(copy),
30 _selected_child(copy._selected_child)
31{
32}
33
34/**
35 * Selects the indicated child for rendering. This is normally called during
36 * the cull_callback() method, but it may be called at any time.
37 */
38INLINE void SelectiveChildNode::
39select_child(int n) {
40 nassertv(n >= 0);
41 _selected_child = n;
42}
A basic node of the scene graph or data graph.
Definition pandaNode.h:65
A base class for nodes like LODNode and SequenceNode that select only one visible child at a time.