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

panda/src/pgraph/accumulatedAttribs.h

Go to the documentation of this file.
00001 // Filename: accumulatedAttribs.h
00002 // Created by:  drose (30Jan03)
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 ACCUMULATEDATTRIBS_H
00020 #define ACCUMULATEDATTRIBS_H
00021 
00022 #include "pandabase.h"
00023 #include "transformState.h"
00024 #include "renderAttrib.h"
00025 #include "renderState.h"
00026 #include "pointerTo.h"
00027 
00028 class PandaNode;
00029 
00030 ///////////////////////////////////////////////////////////////////
00031 //       Class : AccumulatedAttribs
00032 // Description : This class is used by the SceneGraphReducer to
00033 //               maintain and accumulate the set of attributes we have
00034 //               encountered on each node that might eventually be
00035 //               applied to the vertices at the leaves.
00036 ////////////////////////////////////////////////////////////////////
00037 class EXPCL_PANDA AccumulatedAttribs {
00038 public:
00039   INLINE AccumulatedAttribs();
00040   INLINE AccumulatedAttribs(const AccumulatedAttribs &copy);
00041   INLINE void operator = (const AccumulatedAttribs &copy);
00042   
00043   void write(ostream &out, int attrib_types, int indent_level) const;
00044   
00045   void collect(PandaNode *node, int attrib_types);
00046   void apply_to_node(PandaNode *node, int attrib_types);
00047 
00048   CPT(TransformState) _transform;
00049   CPT(RenderAttrib) _color;
00050   CPT(RenderAttrib) _color_scale;
00051   CPT(RenderAttrib) _tex_matrix;
00052   CPT(RenderState) _other;
00053 };
00054 
00055 #include "accumulatedAttribs.I"
00056 
00057 #endif
00058 
00059 

Generated on Fri May 2 00:41:03 2003 for Panda by doxygen1.3