Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

panda/src/pgraph/switchNode.I

Go to the documentation of this file.
00001 // Filename: switchNode.I
00002 // Created by:  drose (31Jul02)
00003 //
00004 ////////////////////////////////////////////////////////////////////
00005 //
00006 // PANDA 3D SOFTWARE
00007 // Copyright (c) 2001, Disney Enterprises, Inc.  All rights reserved
00008 //
00009 // All use of this software is subject to the terms of the Panda 3d
00010 // Software license.  You should have received a copy of this license
00011 // along with this source code; you will also find a current copy of
00012 // the license at http://www.panda3d.org/license.txt .
00013 //
00014 // To contact the maintainers of this program write to
00015 // panda3d@yahoogroups.com .
00016 //
00017 ////////////////////////////////////////////////////////////////////
00018 
00019 
00020 ////////////////////////////////////////////////////////////////////
00021 //     Function: SwitchNode::CData::Constructor
00022 //       Access: Public
00023 //  Description:
00024 ////////////////////////////////////////////////////////////////////
00025 INLINE SwitchNode::CData::
00026 CData() {
00027   _visible_child = 0;
00028 }
00029 
00030 ////////////////////////////////////////////////////////////////////
00031 //     Function: SwitchNode::CData::Copy Constructor
00032 //       Access: Public
00033 //  Description:
00034 ////////////////////////////////////////////////////////////////////
00035 INLINE SwitchNode::CData::
00036 CData(const SwitchNode::CData &copy) :
00037   _visible_child(copy._visible_child)
00038 {
00039 }
00040 
00041 ////////////////////////////////////////////////////////////////////
00042 //     Function: SwitchNode::Constructor
00043 //       Access: Published
00044 //  Description:
00045 ////////////////////////////////////////////////////////////////////
00046 INLINE SwitchNode::
00047 SwitchNode(const string &name) :
00048   SelectiveChildNode(name)
00049 {
00050 }
00051 
00052 ////////////////////////////////////////////////////////////////////
00053 //     Function: SwitchNode::set_visible_child
00054 //       Access: Published
00055 //  Description: Specifies the particular child of this node, by
00056 //               index, that will be visible.
00057 ////////////////////////////////////////////////////////////////////
00058 INLINE void SwitchNode::
00059 set_visible_child(int index) {
00060   CDWriter cdata(_cycler);
00061   cdata->_visible_child = index;
00062 }

Generated on Fri May 2 00:42:26 2003 for Panda by doxygen1.3