VR-Forces 4.8 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
DtSkyDrawable.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 2019 MAK Technologies, Inc.
3 ** All rights reserved.
4 *******************************************************************************/
5 
9 
10 #pragma once
11 
12 #include <vrvOsg/vrvOsg.h>
14 #include <osg/Drawable>
15 
16 namespace SilverLining
17 {
18  class Atmosphere;
19 }
20 
21 namespace osg
22 {
23  class Camera;
24  class GLExtensions;
25 }
26 
27 namespace makVrv
28 {
29  class DtSilverliningGroup;
30 
33  class DT_DLL_VRVOSG DtSkyDrawable : public osg::Drawable
34  {
35 
36  public:
37 
38  friend class DtSkyDrawableCreator;
39 
41  DtSkyDrawable(const DtSkyDrawable& copy, const osg::CopyOp& copyop);
42 
44  virtual ~DtSkyDrawable();
45 
46  META_Object(vrvOsg, DtSkyDrawable)
47 
48 
49  void setGeocentricMode(bool mode);
50 
52  void setLensFlare(bool enabled);
53 
55  virtual void drawImplementation(osg::RenderInfo& renderInfo) const;
56 
58  virtual void releaseGLObjects(osg::State* state = 0) const;
59 
61  void setSkyBoxSize(double size);
62 
64  double getSkyBoxSize() const;
65 
66  protected:
67 
70 
71  void updateSensorFXUniforms(const SilverLining::Atmosphere* atmosphere, const osg::Camera* camera, osg::State& state) const;
72 
73  protected:
74 
76  bool myGeocentricFlag;
77  osg::Vec4f myFogColor;
78  float myFogDensity;
79  double myBoxSize;
80  bool myLensFlareFlag;
81  };
82 
86  {
87  public:
88 
91  static DtSkyDrawableCreator& instance(DtDe& de);
92 
94  static void registerInstance(DtDe& de, DtSkyDrawableCreator* anInstance);
95 
97  virtual DtSkyDrawable* create(DtSilverliningGroup* parent);
98  };
99 
100 }
Virtual base class.
Definition: DtVirtualBaseClass.h:22
#define DT_DLL_VRVOSG
Definition: vrvOsg.h:23
voidpf void uLong size
Definition: ioapi.h:39
A group node which adds a silver-lining sky and will light all Children with the proper lighting para...
Definition: DtSilverliningGroup.h:63
Contains makVrv::DtVirtualBaseClass class.
The sky drawable.
Definition: DtSkyDrawable.h:33
Abstract creator base class.
Definition: DtSkyDrawable.h:85
const char int mode
Definition: ioapi.h:38
Contains DLL export macros.
The DtDe is the core component of any VR-Vantage application.
Definition: DtDe.h:69

Document ID: Generated on Thu Aug 27 10:56:05 EDT 2020 from SVN revision 217100
Copyright © 2005-2020 MAK Technologies. All Rights Reserved (www.mak.com)