VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
DtOsgPrintNodeHierarchyVisitor.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 2025 MAK Technologies, Inc.
3 ** All rights reserved.
4 ******************************************************************************/
5 
9 
10 #pragma once
11 
12 #include <vrvOsg/vrvOsg.h>
13 
14 #include <osg/NodeVisitor>
15 
16 #include <vector>
17 
18 #include <boost/utility/binary.hpp>
19 
20 namespace osg
21 {
22  class ProxyNode;
23  class Switch;
24  class LOD;
25  class Sequence;
26  class Transform;
27 }
28 
29 namespace osgSim
30 {
31  class MultiSwitch;
32  class DOFTransform;
33 }
34 
35 namespace makVrv
36 {
38  class DT_DLL_VRVOSG DtOsgPrintNodeHierarchyVisitor : public osg::NodeVisitor
39  {
40  public:
43 
46 
47  public:
48 
50  {
51  FLAGS_Geometry = BOOST_BINARY(0000 0000 0000 0001)
52  , FLAGS_Geode = BOOST_BINARY(0000 0000 0000 0010)
53  , FLAGS_Node = BOOST_BINARY(0000 0000 0000 0100)
54  , FLAGS_Proxy = BOOST_BINARY(0000 0000 0000 1000)
55  , FLAGS_Switch = BOOST_BINARY(0000 0000 0001 0000)
56  , FLAGS_Lod = BOOST_BINARY(0000 0000 0010 0000)
57  , FLAGS_Sequence = BOOST_BINARY(0000 0100 0000 0000)
58  , FLAGS_Billboard = BOOST_BINARY(0000 1000 0000 0000)
59  , FLAGS_MatrixTransform = BOOST_BINARY(0000 0001 0000 0000)
60  , FLAGS_MultiSwitch = BOOST_BINARY(0000 0010 0000 0000)
61  , FLAGS_DOFTransform = BOOST_BINARY(0000 0100 0000 0000)
62 
63  , FLAGS_Textures = BOOST_BINARY(0000 1000 0000 0000)
64  , FLAGS_All = BOOST_BINARY(0000 1111 1111 1111)
65  };
66  private:
70  DtOsgPrintNodeHierarchyVisitor& operator=(const DtOsgPrintNodeHierarchyVisitor& other) = delete;
71 
72  public:
74  virtual void apply(osg::Geometry& geometry) override;
75 
77  virtual void apply(osg::Geode& geode) override;
78 
80  virtual void apply(osg::Node& node) override;
81 
83  virtual void apply(osg::ProxyNode& node) override;
84 
86  virtual void apply(osg::Switch& node) override;
87 
89  virtual void apply(osg::LOD& node) override;
90 
92  virtual void apply(osg::Sequence& node) override;
93 
95  virtual void apply(osg::Billboard& node) override;
96 
97  virtual void apply(osg::MatrixTransform& node) override;
98 
100  virtual void apply(osgSim::MultiSwitch& node);
101 
103  virtual void apply(osgSim::DOFTransform& node);
104 
107  virtual void apply(osg::Transform& node) override;
108 
110  virtual void setFlags(int flags);
111 
113  static void printHierarchy(const osg::Node* node, PrintFlags flags = FLAGS_All);
114  protected:
115  int myFlags;
116  };
117 }
PrintFlags
Definition: DtOsgPrintNodeHierarchyVisitor.h:49
#define DT_DLL_VRVOSG
Definition: vrvOsg.h:23
visitor for printing out the node hierarchy to the console
Definition: DtOsgPrintNodeHierarchyVisitor.h:38
Contains DLL export macros.
int myFlags
Definition: DtOsgPrintNodeHierarchyVisitor.h:115

Document ID: Generated on Thu Oct 23 22:29:17 EDT 2025 from SVN revision 280951
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)