VR-Forces 5.0.2 Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
DtOsgFogComponent.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 2022 MAK Technologies, Inc.
3 ** All rights reserved.
4 ******************************************************************************/
5 
9 
10 #pragma once
11 
15 
17 
18 namespace osg
19 {
20  class Fog;
21  class StateSet;
22 }
23 
24 namespace makVrv
25 {
26  class DtOsgLightManager;
27  class DtLightingComponentShaderConstants;
28 
34  {
35  public:
36 
39 
41  virtual ~DtOsgFogComponent();
42 
43  private:
44 
47 
49  DtOsgFogComponent &operator=(const DtOsgFogComponent &other);
50 
51  public:
52 
54  virtual void init();
55 
57  virtual bool install(osg::StateSet* stateset);
58 
60  virtual bool uninstall(osg::StateSet* stateset);
61 
63  virtual bool installed(void) const;
64 
67  virtual void setColor(const Vector4_32& fogColor);
68 
71  virtual void setDensity(float fDensity);
72 
75  virtual void setHeightFogPlane(const Vector4_32& fogPlane);
76 
83  virtual void setHeightFogParams(const Vector4_32& fogParams);
84 
87  virtual void setHeightFogColor(const Vector4_32& color);
88 
90  virtual Vector4_32 color(void) const;
91 
93  virtual float density(void) const;
94 
96  virtual Vector4_32 heightFogPlane(void) const;
97 
99  virtual Vector4_32 heightFogParams(void) const;
100 
102  virtual Vector4_32 heightFogColor(void) const;
103  protected:
105  DtLightingComponentShaderConstants* findShaderConstants(void);
107  const DtLightingComponentShaderConstants* findShaderConstants(void) const;
108  protected:
109 
111 
113  };
114 
117 
119  template <>
120  inline const char* creatorTypeName<DtOsgFogComponent>(void) { return "DtOsgFogComponentCreator"; }
121 }
DT_DLL_EXAMPLESCENEROOTPLUGIN void init(DtDe &anIG)
Definition: DtLightingComponentShaderConstants.h:28
#define DT_DLL_VRVOSG
Definition: vrvOsg.h:23
bool myInstalled
Definition: DtOsgFogComponent.h:110
4 dimensional vector
DtOsgLightManager & myOsgLightManager
Definition: DtOsgFogComponent.h:112
Variadic templated creator class for defining a DtVirtualBaseClass creator that is automatically regi...
Definition: DtVirtualBaseClassCreator.h:22
Contains makVrv::DtVirtualBaseClass class.
DtOsgLightManager receives LightSource nodes from the DtOsgCullVisitor, and collects them all here wh...
Definition: DtOsgLightManager.h:51
State component that injects Fog rendering capabilities into a state set.
Definition: DtOsgFogComponent.h:33
DtVirtualBaseClassCreator< DtOsgFogComponent > DtOsgFogComponentCreator
creator
Definition: DtOsgFogComponent.h:116
Base class for components that affect the state on a subset of the scene graph, injecting state...
Definition: DtOsgStateComponent.h:34
const char * creatorTypeName< DtOsgFogComponent >(void)
template specialization for the creator
Definition: DtOsgFogComponent.h:120
The DtDe is the core component of any VR-Vantage application. It owns a DtRenderer, DtDeCommunicator, as well as a DtDisplay and other things.
Definition: DtDe.h:70
Contains makVrv::DtOsgStateComponent class.

Document ID: Generated on Sun Dec 4 20:22:03 EST 2022 from SVN revision 249613
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)