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

panda/src/tform/transform2sg.h

Go to the documentation of this file.
00001 // Filename: transform2sg.h
00002 // Created by:  drose (12Mar02)
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 #ifndef TRANSFORM2SG_H
00020 #define TRANSFORM2SG_H
00021 
00022 #include "pandabase.h"
00023 
00024 #include "dataNode.h"
00025 #include "pandaNode.h"
00026 
00027 ////////////////////////////////////////////////////////////////////
00028 //       Class : Transform2SG
00029 // Description : input: Transform (matrix)
00030 //
00031 //               output: none, but applies the matrix as the transform
00032 //               transition for a given arc of the scene graph.
00033 ////////////////////////////////////////////////////////////////////
00034 class EXPCL_PANDA Transform2SG : public DataNode {
00035 PUBLISHED:
00036   Transform2SG(const string &name);
00037 
00038   void set_node(PandaNode *node);
00039   PandaNode *get_node() const;
00040 
00041   void set_velocity_node(PandaNode *node);
00042   PandaNode *get_velocity_node() const;
00043 
00044 private:
00045   PandaNode *_node;
00046   PandaNode *_velocity_node;
00047 
00048 protected:
00049   // Inherited from DataNode
00050   virtual void do_transmit_data(const DataNodeTransmit &input,
00051                                 DataNodeTransmit &output);
00052 
00053 private:
00054   // inputs
00055   int _transform_input;
00056   int _velocity_input;
00057 
00058 public:
00059   static TypeHandle get_class_type() {
00060     return _type_handle;
00061   }
00062   static void init_type() {
00063     DataNode::init_type();
00064     register_type(_type_handle, "Transform2SG",
00065                   DataNode::get_class_type());
00066   }
00067   virtual TypeHandle get_type() const {
00068     return get_class_type();
00069   }
00070   virtual TypeHandle force_init_type() {init_type(); return get_class_type();}
00071 
00072 private:
00073   static TypeHandle _type_handle;
00074 };
00075 
00076 #endif
00077 

Generated on Fri May 2 00:44:32 2003 for Panda by doxygen1.3