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

DynamicVertices Class Reference

#include <dynamicVertices.h>

Inheritance diagram for DynamicVertices:

TypedWritable TypedObject List of all members.

Public Member Functions

 DynamicVertices ()
 DynamicVertices (const DynamicVertices &copy)
 Makes a copy of the DynamicVertices object by reference: the new copy shares the same pointers as the original.

virtual void write_datagram (BamWriter *manager, Datagram &me)
 Function to write the important information in the particular object to a Datagram.

void fillin (DatagramIterator &scan, BamReader *manager)
 Function that reads out of the datagram (or asks manager to read) all of the data that is needed to re-create this object and stores it in the appropiate place.

virtual TypeHandle get_type () const
virtual TypeHandle force_init_type ()
virtual int complete_pointers (TypedWritable **p_list, BamReader *manager)
 Receives an array of pointers, one for each time manager->read_pointer() was called in fillin().

virtual void finalize ()
 Called by the BamReader to perform any final actions needed for setting up the object after all objects have been read and all pointers have been completed.

int get_type_index () const
 Returns the internal index number associated with this object's TypeHandle, a unique number for each different type.

bool is_of_type (TypeHandle handle) const
 Returns true if the current object is or derives from the indicated type.

bool is_exact_type (TypeHandle handle) const
 Returns true if the current object is the indicated type exactly.


Static Public Member Functions

DynamicVertices deep_copy (const DynamicVertices &copy)
 Makes a complete copy of the indicated DynamicVertices object, including copying all of its arrays.

TypeHandle get_class_type ()
void init_type ()
 This function is declared non-inline to work around a compiler bug in g++ 2.96.


Public Attributes

PTA_Vertexf _coords
PTA_Normalf _norms
PTA_Colorf _colors
PTA_TexCoordf _texcoords

Static Public Attributes

TypedWritable *const Null = (TypedWritable*)0L

Static Private Attributes

TypeHandle _type_handle

Constructor & Destructor Documentation

DynamicVertices::DynamicVertices  ) 
 

Definition at line 40 of file dynamicVertices.cxx.

DynamicVertices::DynamicVertices const DynamicVertices &  copy  ) 
 

Makes a copy of the DynamicVertices object by reference: the new copy shares the same pointers as the original.

Definition at line 56 of file dynamicVertices.cxx.

References _colors, _coords, _norms, _texcoords, PointerToArray< TexCoordf >::empty(), PointerToArray< Colorf >::empty(), PointerToArray< Normalf >::empty(), PointerToArray< Vertexf >::empty(), PointerToArray< Colorf >::empty_array(), PointerToArray< Normalf >::empty_array(), PointerToArray< Vertexf >::empty_array(), PointerToArray< Colorf >::v(), PointerToArray< Normalf >::v(), and PointerToArray< Vertexf >::v().


Member Function Documentation

int TypedWritable::complete_pointers TypedWritable **  p_list,
BamReader manager
[virtual, inherited]
 

Receives an array of pointers, one for each time manager->read_pointer() was called in fillin().

Returns the number of pointers processed.

This is the callback function that is made by the BamReader at some later point, after all of the required pointers have been filled in. It is necessary because there might be forward references in a bam file; when we call read_pointer() in fillin(), the object may not have been read from the file yet, so we do not have a pointer available at that time. Thus, instead of returning a pointer, read_pointer() simply reserves a later callback. This function provides that callback. The calling object is responsible for keeping track of the number of times it called read_pointer() and extracting the same number of pointers out of the supplied vector, and storing them appropriately within the object.

Reimplemented in AnimBundleNode, AnimGroup, PartBundleNode, PartGroup, Character, CharacterJoint, CollisionNode, GeomSprite, PiecewiseCurve, ClipPlaneAttrib, FogAttrib, LensNode, LightAttrib, MaterialAttrib, RenderEffects, RenderState, TextureAttrib, Person, and Child.

Definition at line 94 of file typedWritable.cxx.

Referenced by RenderState::do_invert_compose().

DynamicVertices DynamicVertices::deep_copy const DynamicVertices &  copy  )  [static]
 

Makes a complete copy of the indicated DynamicVertices object, including copying all of its arrays.

Definition at line 77 of file dynamicVertices.cxx.

void DynamicVertices::fillin DatagramIterator scan,
BamReader manager
 

Function that reads out of the datagram (or asks manager to read) all of the data that is needed to re-create this object and stores it in the appropiate place.

Reimplemented from TypedWritable.

Definition at line 132 of file dynamicVertices.cxx.

void TypedWritable::finalize void   )  [virtual, inherited]
 

Called by the BamReader to perform any final actions needed for setting up the object after all objects have been read and all pointers have been completed.

Reimplemented in PartBundle, RenderAttrib, RenderEffect, RenderEffects, RenderState, and TransformState.

Definition at line 112 of file typedWritable.cxx.

Referenced by BamReader::skip_pointer().

virtual TypeHandle DynamicVertices::force_init_type void   )  [inline, virtual]
 

Reimplemented from TypedWritable.

Definition at line 63 of file dynamicVertices.h.

TypeHandle DynamicVertices::get_class_type void   )  [inline, static]
 

Reimplemented from TypedWritable.

Definition at line 64 of file dynamicVertices.h.

virtual TypeHandle DynamicVertices::get_type void   )  const [inline, virtual]
 

Reimplemented from TypedWritable.

Definition at line 60 of file dynamicVertices.h.

int TypedObject::get_type_index  )  const [inline, inherited]
 

Returns the internal index number associated with this object's TypeHandle, a unique number for each different type.

This is equivalent to get_type().get_index().

Definition at line 71 of file typedObject.I.

References TypeHandle::get_name(), TypedObject::get_type(), and INLINE.

void DynamicVertices::init_type void   )  [inline, static]
 

This function is declared non-inline to work around a compiler bug in g++ 2.96.

Making it inline seems to cause problems in the optimizer.

Reimplemented from TypedWritable.

Definition at line 67 of file dynamicVertices.h.

bool TypedObject::is_exact_type TypeHandle  handle  )  const [inline, inherited]
 

Returns true if the current object is the indicated type exactly.

Definition at line 101 of file typedObject.I.

Referenced by PT(), and CollisionNode::xform().

bool TypedObject::is_of_type TypeHandle  handle  )  const [inline, inherited]
 

Returns true if the current object is or derives from the indicated type.

Definition at line 86 of file typedObject.I.

Referenced by EggMaterialCollection::collapse_equivalent_materials(), EggTextureCollection::collapse_equivalent_textures(), DeferredNodeProperty::compose(), AnimBundleMaker::create_s_channel(), CharacterMaker::create_slider(), ProjectionScreen::cull_callback(), DataNode::define_output(), EggNode::determine_draw_order(), CharacterMaker::egg_to_index(), EggGroupUniquifier::EggGroupUniquifier(), EggPoolUniquifier::EggPoolUniquifier(), EggGroupNode::find_textures(), StaticTextFont::get_glyph(), EggMaterialCollection::insert_materials(), EggTextureCollection::insert_textures(), CharacterJoint::make_copy(), PT(), EggGroupNode::r_flatten_transforms(), EggGroupNode::r_transform_vertices(), EggGroupNode::recompute_polygon_normals(), CollisionLevelState::reserve(), PandaFramework::reset_frame_rate(), PandaFramework::set_texture(), EggGroupNode::steal_children(), and DataGraphTraverser::traverse().

void DynamicVertices::write_datagram BamWriter manager,
Datagram me
[virtual]
 

Function to write the important information in the particular object to a Datagram.

Reimplemented from TypedWritable.

Definition at line 109 of file dynamicVertices.cxx.


Member Data Documentation

PTA_Colorf DynamicVertices::_colors
 

Definition at line 52 of file dynamicVertices.h.

Referenced by DynamicVertices(), and ComputedVertices::VertexTransform::read_datagram().

PTA_Vertexf DynamicVertices::_coords
 

Definition at line 50 of file dynamicVertices.h.

Referenced by DynamicVertices(), and ComputedVertices::VertexTransform::read_datagram().

PTA_Normalf DynamicVertices::_norms
 

Definition at line 51 of file dynamicVertices.h.

Referenced by DynamicVertices(), and ComputedVertices::VertexTransform::read_datagram().

PTA_TexCoordf DynamicVertices::_texcoords
 

Definition at line 53 of file dynamicVertices.h.

Referenced by DynamicVertices(), and ComputedVertices::VertexTransform::read_datagram().

TypeHandle DynamicVertices::_type_handle [static, private]
 

Reimplemented from TypedWritable.

Definition at line 30 of file dynamicVertices.cxx.

TypedWritable *const TypedWritable::Null = (TypedWritable*)0L [static, inherited]
 

Definition at line 25 of file typedWritable.cxx.

Referenced by Child::complete_pointers(), Parent::complete_pointers(), Person::complete_pointers(), LoaderFileTypeBam::get_extension(), PartGroup::pick_channel_index(), BamReader::read_pointer(), and AnimGroup::write_datagram().


The documentation for this class was generated from the following files:
Generated on Fri May 2 00:49:45 2003 for Panda by doxygen1.3