Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

osg::SingleTypeGraphOp< Type > Class Template Reference
[Rendering BackendGeometry]

#include <OSGSingleTypeGraphOp.h>

Inheritance diagram for osg::SingleTypeGraphOp< Type >:

osg::GraphOp osg::StripeGraphOp List of all members.

Main methods

*virtual bool traverse (NodePtr &root)
const std::string & getName (void)
void setName (const char *name)

Public Member Functions

Constructors
SingleTypeGraphOp (const char *name="")
Destructors
*virtual ~SingleTypeGraphOp (void)
Constructors
virtual GraphOpcreate (void)=0
Parameters
*virtual void setParams (const std::string params)=0
virtual std::string usage (void)=0

Static Public Member Functions

Class Get
*static const char * getClassname (void)

Protected Member Functions

virtual bool travNodeEnter (NodePtr node)=0
virtual bool travNodeLeave (NodePtr node)=0

Protected Attributes

std::list< NodePtr_excludeListNodes
std::list< std::string > _excludeListNames

Private Member Functions

Action::ResultE traverseEnter (NodePtr &node)
Action::ResultE traverseLeave (NodePtr &node, Action::ResultE res)

Detailed Description

template<class Type>
class osg::SingleTypeGraphOp< Type >

GraphOp class

Definition at line 57 of file OSGSingleTypeGraphOp.h.


Constructor & Destructor Documentation

template<class Type>
SingleTypeGraphOp::SingleTypeGraphOp const char *  name = ""  )  [inline]
 

Definition at line 69 of file OSGSingleTypeGraphOp.inl.

00069                                                           : GraphOp(name)
00070 {
00071 }

template<class Type>
SingleTypeGraphOp::~SingleTypeGraphOp void   )  [inline, virtual]
 

Definition at line 74 of file OSGSingleTypeGraphOp.inl.

00075 {
00076 }


Member Function Documentation

template<class Type>
* static const char* osg::SingleTypeGraphOp< Type >::getClassname void   )  [inline, static]
 

Reimplemented from osg::GraphOp.

Reimplemented in osg::GeoTypeGraphOp, osg::StripeGraphOp, and osg::VerifyGeoGraphOp.

Definition at line 66 of file OSGSingleTypeGraphOp.h.

00066 { return "SingleTypeGraphOp"; };

template<class Type>
virtual bool osg::SingleTypeGraphOp< Type >::travNodeEnter NodePtr  node  )  [protected, pure virtual]
 

Implemented in osg::GeoTypeGraphOp, osg::StripeGraphOp, and osg::VerifyGeoGraphOp.

Referenced by osg::SingleTypeGraphOp< Type >::traverseEnter().

template<class Type>
virtual bool osg::SingleTypeGraphOp< Type >::travNodeLeave NodePtr  node  )  [protected, pure virtual]
 

Implemented in osg::GeoTypeGraphOp, osg::StripeGraphOp, and osg::VerifyGeoGraphOp.

Referenced by osg::SingleTypeGraphOp< Type >::traverseLeave().

template<class Type>
Action::ResultE SingleTypeGraphOp::traverseEnter NodePtr node  )  [inline, private, virtual]
 

Implements osg::GraphOp.

Definition at line 79 of file OSGSingleTypeGraphOp.inl.

References osg::Action::Continue, osg::NodePtr::getCore(), osg::NodeCore::getType(), osg::FieldContainerType::isDerivedFrom(), and osg::SingleTypeGraphOp< Type >::travNodeEnter().

00080 {
00081     if (node->getCore()->getType().isDerivedFrom(Type::getClassType()))
00082         travNodeEnter(node);
00083     return Action::Continue;
00084 }

template<class Type>
Action::ResultE SingleTypeGraphOp::traverseLeave NodePtr node,
Action::ResultE  res
[inline, private, virtual]
 

Implements osg::GraphOp.

Definition at line 87 of file OSGSingleTypeGraphOp.inl.

References osg::Action::Continue, osg::NodePtr::getCore(), osg::NodeCore::getType(), osg::FieldContainerType::isDerivedFrom(), and osg::SingleTypeGraphOp< Type >::travNodeLeave().

00089 {
00090     if (node->getCore()->getType().isDerivedFrom(Type::getClassType()))
00091         travNodeLeave(node);
00092     return Action::Continue;
00093 }

virtual GraphOp* osg::GraphOp::create void   )  [pure virtual, inherited]
 

Implemented in osg::GeoTypeGraphOp, osg::MakeTransparentGraphOp, osg::MaterialMergeGraphOp, osg::MergeGraphOp, osg::PruneGraphOp, osg::SharePtrGraphOp, osg::SplitGraphOp, osg::StripeGraphOp, osg::VerifyGeoGraphOp, and osg::VerifyGraphOp.

Referenced by osg::GraphOpFactory::create().

* virtual void osg::GraphOp::setParams const std::string  params  )  [pure virtual, inherited]
 

Implemented in osg::GeoTypeGraphOp, osg::MakeTransparentGraphOp, osg::MaterialMergeGraphOp, osg::MergeGraphOp, osg::PruneGraphOp, osg::SharePtrGraphOp, osg::SplitGraphOp, osg::StripeGraphOp, osg::VerifyGeoGraphOp, and osg::VerifyGraphOp.

Referenced by osg::GraphOpSeq::setGraphOps().

virtual std::string osg::GraphOp::usage void   )  [pure virtual, inherited]
 

Implemented in osg::GeoTypeGraphOp, osg::MakeTransparentGraphOp, osg::MaterialMergeGraphOp, osg::MergeGraphOp, osg::PruneGraphOp, osg::SharePtrGraphOp, osg::SplitGraphOp, osg::StripeGraphOp, osg::VerifyGeoGraphOp, and osg::VerifyGraphOp.

bool GraphOp::traverse NodePtr root  )  [virtual, inherited]
 

Reimplemented in osg::MakeTransparentGraphOp, osg::MaterialMergeGraphOp, osg::MergeGraphOp, osg::SharePtrGraphOp, osg::SplitGraphOp, and osg::VerifyGraphOp.

Definition at line 94 of file OSGGraphOp.cpp.

References osg::Action::Continue, osg::osgTypedMethodFunctor1ObjPtrCPtrRef(), osg::osgTypedMethodFunctor2ObjPtrCPtrRef(), osg::GraphOp::traverseEnter(), and osg::GraphOp::traverseLeave().

Referenced by osg::VerifyGraphOp::traverse(), osg::MaterialMergeGraphOp::traverse(), and osg::MakeTransparentGraphOp::traverse().

00095 {
00096     Action::ResultE res;
00097     res = ::traverse(node,
00098           osgTypedMethodFunctor1ObjPtrCPtrRef<Action::ResultE,
00099           GraphOp,
00100           NodePtr>(this,&GraphOp::traverseEnter),
00101           osgTypedMethodFunctor2ObjPtrCPtrRef<Action::ResultE,
00102           GraphOp,
00103           NodePtr,
00104           Action::ResultE>(this,&GraphOp::traverseLeave));
00105 
00106     if (res == Action::Continue) 
00107         return true;
00108     else 
00109         return false;
00110 }

const std::string & GraphOp::getName void   )  [inherited]
 

Definition at line 112 of file OSGGraphOp.cpp.

References osg::GraphOp::_name.

Referenced by osg::GraphOpFactory::registerOp(), and osg::GraphOpFactory::unRegisterOp().

00113 {
00114     return _name;
00115 };

void GraphOp::setName const char *  name  )  [inherited]
 

Definition at line 117 of file OSGGraphOp.cpp.

References osg::GraphOp::_name.

00118 {
00119     _name = name;
00120 };

void GraphOp::addToExcludeList NodePtr node  )  [inherited]
 

Definition at line 124 of file OSGGraphOp.cpp.

References osg::GraphOp::_excludeListNodes, and osg::GraphOp::isInExcludeListNodes().

Referenced by osg::MergeGraphOp::excludeListLeave(), and osg::GraphOpSeq::setGraphOps().

00125 {
00126     if (!isInExcludeListNodes(node))
00127         _excludeListNodes.push_back(node);
00128 }

void GraphOp::addToExcludeList const std::string &  name  )  [inherited]
 

Definition at line 130 of file OSGGraphOp.cpp.

References osg::GraphOp::_excludeListNames, and osg::GraphOp::isInExcludeListNames().

00131 {
00132     if (!isInExcludeListNames(name))
00133         _excludeListNames.push_back(name);
00134 }

void GraphOp::removeFromExcludeList NodePtr node  )  [inherited]
 

Definition at line 136 of file OSGGraphOp.cpp.

References osg::GraphOp::_excludeListNodes.

00137 {
00138     _excludeListNodes.remove(node);
00139 }

void GraphOp::removeFromExcludeList const std::string &  name  )  [inherited]
 

Definition at line 141 of file OSGGraphOp.cpp.

References osg::GraphOp::_excludeListNames.

00142 {
00143     _excludeListNames.remove(name);
00144 }

void GraphOp::clearExcludeList void   )  [inherited]
 

Definition at line 146 of file OSGGraphOp.cpp.

References osg::GraphOp::_excludeListNames, and osg::GraphOp::_excludeListNodes.

00147 {
00148     _excludeListNames.clear();
00149     _excludeListNodes.clear();
00150 }

bool GraphOp::isInExcludeListNodes NodePtr node  )  [inherited]
 

Definition at line 152 of file OSGGraphOp.cpp.

References osg::GraphOp::_excludeListNodes.

Referenced by osg::GraphOp::addToExcludeList(), and osg::GraphOp::isInExcludeList().

00153 {
00154     std::list<NodePtr>::iterator list_iter;
00155     list_iter = std::find(_excludeListNodes.begin(),_excludeListNodes.end(),node);
00156 
00157     if (list_iter==_excludeListNodes.end()) 
00158         return false;
00159     else 
00160         return true;
00161 }

bool GraphOp::isInExcludeListNames const std::string &  name  )  [inherited]
 

Definition at line 163 of file OSGGraphOp.cpp.

References osg::GraphOp::_excludeListNames.

Referenced by osg::GraphOp::addToExcludeList(), and osg::GraphOp::isInExcludeList().

00164 {
00165     std::list<std::string>::iterator namelist_iter;
00166     namelist_iter = std::find(_excludeListNames.begin(),_excludeListNames.end(),name);
00167 
00168     if (namelist_iter==_excludeListNames.end()) 
00169         return false;
00170     else 
00171         return true;
00172 }

bool GraphOp::isInExcludeList NodePtr node  )  [inherited]
 

Definition at line 174 of file OSGGraphOp.cpp.

References osg::getName(), osg::GraphOp::isInExcludeListNames(), and osg::GraphOp::isInExcludeListNodes().

Referenced by osg::MergeGraphOp::processGeometries(), osg::MergeGraphOp::processGroups(), osg::MergeGraphOp::processTransformations(), osg::SplitGraphOp::splitNode(), and osg::SplitGraphOp::traverseLeave().

00175 {
00176     if (isInExcludeListNodes(node) || (OSG::getName(node)!=NULL && isInExcludeListNames(OSG::getName(node))))
00177         return true;
00178     else
00179         return false;
00180 }


Member Data Documentation

std::list<NodePtr> osg::GraphOp::_excludeListNodes [protected, inherited]
 

Definition at line 161 of file OSGGraphOp.h.

Referenced by osg::GraphOp::addToExcludeList(), osg::GraphOp::clearExcludeList(), osg::GraphOp::isInExcludeListNodes(), osg::MergeGraphOp::mergeOnce(), and osg::GraphOp::removeFromExcludeList().

std::list<std::string> osg::GraphOp::_excludeListNames [protected, inherited]
 

Definition at line 162 of file OSGGraphOp.h.

Referenced by osg::GraphOp::addToExcludeList(), osg::GraphOp::clearExcludeList(), osg::GraphOp::isInExcludeListNames(), and osg::GraphOp::removeFromExcludeList().


The documentation for this class was generated from the following files:
Generated on Thu Aug 25 04:14:11 2005 for OpenSG by  doxygen 1.4.3