Panda3D
Public Member Functions | Public Attributes

AccumulatedAttribs Class Reference

This class is used by the SceneGraphReducer to maintain and accumulate the set of attributes we have encountered on each node that might eventually be applied to the vertices at the leaves. More...

#include "accumulatedAttribs.h"

List of all members.

Public Member Functions

 AccumulatedAttribs (const AccumulatedAttribs &copy)
void apply_to_node (PandaNode *node, int attrib_types)
 Stores the indicated attributes in the node's transform and state information; does not attempt to apply the properties to the vertices.
void collect (PandaNode *node, int attrib_types)
 Collects the state and transform from the indicated node and adds it to the accumulator, removing it from the node.
 CPT (RenderAttrib) _clip_plane
 CPT (RenderAttrib) _tex_matrix
 CPT (RenderAttrib) _color_scale
 CPT (TransformState) _transform
 CPT (RenderAttrib) _color
 CPT (RenderState) collect(const RenderState *state
 CPT (RenderAttrib) _texture
 CPT (RenderState) _other
 CPT (RenderAttrib) _cull_face
void operator= (const AccumulatedAttribs &copy)
void write (ostream &out, int attrib_types, int indent_level) const

Public Attributes

int _clip_plane_override
int _color_override
int _color_scale_override
int _cull_face_override
int _tex_matrix_override
int _texture_override
int attrib_types

Detailed Description

This class is used by the SceneGraphReducer to maintain and accumulate the set of attributes we have encountered on each node that might eventually be applied to the vertices at the leaves.

Definition at line 33 of file accumulatedAttribs.h.


Member Function Documentation

void AccumulatedAttribs::apply_to_node ( PandaNode node,
int  attrib_types 
)

Stores the indicated attributes in the node's transform and state information; does not attempt to apply the properties to the vertices.

Clears the attributes from the accumulator for future traversals.

Definition at line 305 of file accumulatedAttribs.cxx.

References PandaNode::get_attrib(), PandaNode::get_state(), PandaNode::get_transform(), PandaNode::reset_prev_transform(), PandaNode::set_attrib(), PandaNode::set_state(), and PandaNode::set_transform().

Referenced by SceneGraphReducer::r_apply_attribs().

void AccumulatedAttribs::collect ( PandaNode node,
int  attrib_types 
)

Collects the state and transform from the indicated node and adds it to the accumulator, removing it from the node.

Definition at line 149 of file accumulatedAttribs.cxx.

References PandaNode::get_state(), PandaNode::get_transform(), PandaNode::set_prev_transform(), PandaNode::set_state(), and PandaNode::set_transform().

Referenced by GeomNode::apply_attribs_to_vertices(), and SceneGraphReducer::r_apply_attribs().


The documentation for this class was generated from the following files:
 All Classes Functions Variables Enumerations