VR-Forces 4.10 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
DtLightManagerGroup.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 2012 MAK Technologies, Inc.
3 ** All rights reserved.
4 ******************************************************************************/
5 
9 
10 #ifndef DtLightManagerGroup_H_
11 #define DtLightManagerGroup_H_
12 
15 #include <osg/Group>
16 
17 namespace makVrv
18 {
23  class DT_DLL_VRVOSG DtLightManagerGroup : public osg::Group
24  {
25  public:
26 
29 
32  const osg::CopyOp& copyOp = osg::CopyOp::SHALLOW_COPY) :
33  Group(lmg, copyOp), myDe(lmg.myDe),
34  myLightManagerStateAttribute(dynamic_cast<DtLightManagerStateAttribute *>
35  (copyOp(lmg.myLightManagerStateAttribute.get())))
36  {
37  }
38 
39  // OSG required overrides:
40  virtual osg::Object* cloneType() const
41  {
42  return new DtLightManagerGroup (myDe);
43  }
44 
45  virtual osg::Object* clone(const osg::CopyOp& copyop) const
46  {
47  return new DtLightManagerGroup (*this,copyop);
48  }
49 
50  virtual bool isSameKindAs(const osg::Object* obj) const
51  {
52  return dynamic_cast<const DtLightManagerGroup *>(obj)!=NULL;
53  }
54 
55  virtual const char* className() const
56  {
57  return "DtLightManagerGroup";
58  }
59 
60  virtual const char* libraryName() const
61  {
62  return "vrvOsg";
63  }
64 
65  virtual void accept(osg::NodeVisitor& nv)
66  {
67  if (nv.validNodeMask(*this))
68  {
69  nv.pushOntoNodePath(this);
70  nv.apply(*this);
71  nv.popFromNodePath();
72  }
73  }
74 
76  virtual ~DtLightManagerGroup();
77 
79  void setStateSetModes(osg::StateSet&,
80  osg::StateAttribute::GLModeValue) const;
81 
83  void setLocalStateSetModes(osg::StateAttribute::GLModeValue =
84  osg::StateAttribute::ON);
85 
86  virtual void setThreadSafeRefUnref(bool threadSafe);
87 
88  virtual osg::BoundingSphere computeBound() const;
89 
90  void enableLighting(osg::ref_ptr<osg::Camera> camera, bool enable);
91 
92  protected:
95  };
96 
97 }
98 
99 #endif
100 
A group node which applies lights maintained in the DtOsgLightManager at the top of the render graph...
Definition: DtLightManagerGroup.h:23
virtual osg::Object * clone(const osg::CopyOp &copyop) const
Definition: DtLightManagerGroup.h:45
virtual bool isSameKindAs(const osg::Object *obj) const
Definition: DtLightManagerGroup.h:50
#define DT_DLL_VRVOSG
Definition: vrvOsg.h:23
T get(const DtAStarGraph::DynamicPropertyMap< T > &map, size_t index)
Definition: aStarGraph.h:462
virtual const char * className() const
Definition: DtLightManagerGroup.h:55
Contains makVrv::DtOsgLightManager class.
Contains makVrv::DtLightManagerStateAttribute class.
virtual osg::Object * cloneType() const
Definition: DtLightManagerGroup.h:40
DtLightManagerGroup(const DtLightManagerGroup &lmg, const osg::CopyOp &copyOp=osg::CopyOp::SHALLOW_COPY)
copy constructor
Definition: DtLightManagerGroup.h:31
osg::ref_ptr< DtLightManagerStateAttribute > myLightManagerStateAttribute
Definition: DtLightManagerGroup.h:93
virtual const char * libraryName() const
Definition: DtLightManagerGroup.h:60
DtDe & myDe
Definition: DtLightManagerGroup.h:94
virtual void accept(osg::NodeVisitor &nv)
Definition: DtLightManagerGroup.h:65
The DtDe is the core component of any VR-Vantage application.
Definition: DtDe.h:69
A group node which applies lights maintained in the DtOsgLightManager at the top of the render graph...
Definition: DtLightManagerStateAttribute.h:24

Document ID: Generated on Tue Sep 21 17:42:52 EDT 2021 from SVN revision 234861
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)