class SG_EXPORT osg::Billboard: public Geode

Billboard - a Geode which orientates its child osg::GeoSet's to face the eye point.

Inheritance:


Public Classes

[more]enum Mode

Public Methods

[more] Billboard()
[more]virtual Object* clone() const
[more]virtual bool isSameKindAs(Object* obj)
[more]virtual const char* className() const
[more]virtual void accept(NodeVisitor& nv)
[more]void setAxis(const Vec3& axis)
[more]void getAxis(Vec3& axis) const
[more]void setMode(Mode mode)
[more]int getMode() const
[more]void setPos(int i, const Vec3& pos)
[more]void getPos(int i, Vec3& pos) const
[more]virtual bool addGeoSet( GeoSet *gset )
Add GeoSet to Billboard with default position(0,0,0); If gset not NULL and is not contained in Billboard then increment its reference count, and dirty the bounding box to cause it to recompute on next getBound() and return true for success.
[more]virtual bool addGeoSet(GeoSet *gset, const Vec3& pos)
Add GeoSet to Geode at position pos.
[more]virtual bool removeGeoSet( GeoSet *gset )
Remove GeoSet and associated position from Billboard.
[more]void calcRotation(const Vec3& eye_local, const Vec3& pos_local, Matrix& mat)
[more]void calcTransform(const Vec3& eye_local, const Vec3& pos_local, Matrix& mat)

Protected Fields

[more]Mode _mode
[more]Vec3 _axis
[more]PositionList _positionList

Protected Methods

[more]virtual ~Billboard()
[more]virtual bool readLocalData(Input& fr)
[more]virtual bool writeLocalData(Output& fw)
[more]virtual bool computeBound( void )

Protected

[more]typedef std::vector<Vec3> PositionList


Inherited from Geode:

Public Methods

ovirtual bool replaceGeoSet( GeoSet *origGset, GeoSet *newGset )
oint getNumGeoSets( void ) const
oGeoSet* getGeoSet( int i )
obool containsGeoSet(const GeoSet* gset)
oGeoSetList::iterator findGeoSet(const GeoSet* gset)
ovoid compileGeoSets( void )

Public

otypedef std::vector< ref_ptr<GeoSet> > GeoSetList

Protected Fields

oGeoSetList _geosets


Inherited from Node:

Public Methods

oNode* cloneNode() const
ovirtual void ascend(NodeVisitor& nv)
ovirtual void traverse(NodeVisitor& )
ovoid setName( const std::string& name )
ovoid setName( const char* name )
oconst std::string& getName( void )
oconst ParentList& getParents() const
oGroup* getParent(int i) const
oint getNumParents() const
ovoid setUserData(void* data, MemoryAdapter* ma=0L)
ovoid* getUserData() const
oMemoryAdapter* getMemoryAdapter() const
ovoid setNodeMask(NodeMask nm)
oNodeMask getNodeMask()
oconst DescriptionList& getDescriptions() const
oDescriptionList& getDescriptions()
oconst std::string& getDescription(int i) const
ostd::string& getDescription(int i)
oint getNumDescriptions() const
ovoid addDescription(const std::string& desc)
oconst BoundingSphere& getBound()
ovoid dirtyBound()

Public

otypedef std::vector<Group*> ParentList
otypedef unsigned int NodeMask
otypedef std::vector<std::string> DescriptionList

Protected Fields

oBoundingSphere _bsphere
obool _bsphere_computed
ostd::string _name
oParentList _parents
ofriend Group
ovoid* _userData
oref_ptr<MemoryAdapter> _memoryAdapter
oNodeMask _nodeMask
oDescriptionList _descriptions


Inherited from Object:

Public Methods

ovirtual Object* readClone(Input& fr)
ovirtual bool write(Output& fw)


Inherited from Referenced:

Public Methods

oReferenced& operator = (Referenced&)
ovoid ref()
ovoid unref()
oint referenceCount()

Protected Fields

oint _refCount


Documentation

Billboard - a Geode which orientates its child osg::GeoSet's to face the eye point. Typical uses are for trees, or particle explosions.
oenum Mode

o AXIAL_ROT

o POINT_ROT_EYE

o POINT_ROT_WORLD

o Billboard()

ovirtual Object* clone() const

ovirtual bool isSameKindAs(Object* obj)

ovirtual const char* className() const

ovirtual void accept(NodeVisitor& nv)

ovoid setAxis(const Vec3& axis)

ovoid getAxis(Vec3& axis) const

ovoid setMode(Mode mode)

oint getMode() const

ovoid setPos(int i, const Vec3& pos)

ovoid getPos(int i, Vec3& pos) const

ovirtual bool addGeoSet( GeoSet *gset )
Add GeoSet to Billboard with default position(0,0,0); If gset not NULL and is not contained in Billboard then increment its reference count, and dirty the bounding box to cause it to recompute on next getBound() and return true for success. Otherwise return false.

ovirtual bool addGeoSet(GeoSet *gset, const Vec3& pos)
Add GeoSet to Geode at position pos. If gset not NULL and is not contained in Billboard then increment its reference count, and dirty the bounding box to cause it to recompute on next getBound() and return true for success. Otherwise return false.

ovirtual bool removeGeoSet( GeoSet *gset )
Remove GeoSet and associated position from Billboard. If gset is contained in Billboard then remove it from the geoset list and decrement its reference count, and dirty the bounding box to cause it to recompute on next getBound() and return true for success. If gset is not found then return false and do not the reference count of gset is left unchanged.

ovoid calcRotation(const Vec3& eye_local, const Vec3& pos_local, Matrix& mat)

ovoid calcTransform(const Vec3& eye_local, const Vec3& pos_local, Matrix& mat)

ovirtual ~Billboard()

ovirtual bool readLocalData(Input& fr)

ovirtual bool writeLocalData(Output& fw)

ovirtual bool computeBound( void )

otypedef std::vector<Vec3> PositionList

oMode _mode

oVec3 _axis

oPositionList _positionList


This class has no child classes.

Alphabetic index HTML hierarchy of classes or Java



This page was generated with the help of DOC++.