VR-Forces 5.0.1 Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
DtDepthOfFieldDrawable.h
Go to the documentation of this file.
1 /*****************************************************************************
2 * Copyright (c) 2020 MAK Technologies, Inc.
3 * All rights reserved.
4 *****************************************************************************/
5 
6 #pragma once
7 
11 
14 
16 
18 
19 #include <osg/Texture>
20 
21 namespace osg
22 {
23  class Texture2D;
24  class State;
25 }
26 
27 namespace makVrv
28 {
29  class DtDe;
30  class DtGlProgram;
31 
33  struct DtDofParams
34  {
35  double camNear;
36  double camFar;
37 
42 
43  int viewWidth;
45 
47  DtDofParams();
48  };
49 
50 
53 
55  template <>
56  inline const char* creatorTypeName<DtDepthOfFieldDrawable>(void) { return "DtDepthOfFieldDrawableCreator"; }
57 
61  {
62  public:
64  virtual ~DtDepthOfFieldDrawable();
65  protected:
68 
71  private:
74 
77 
80 
81  public:
83  virtual void drawImplementation(osg::RenderInfo& renderInfo) const;
84 
91  //virtual void releaseGLObjects(osg::State* state = 0) const;
92 
94  virtual void setDepthTexture(osg::Texture* texture);
95 
97  virtual void setParams(DtDofParams& params);
98  protected:
100  virtual void createProgramIfNecessary(void) const;
101 
102  virtual void cleanupGpuMemory(void);
103  protected:
106 
109 
112 
121 
122  Vector2_32 myVrvFilterTaps[12];
123 
126  mutable bool myMutableTapsDirty;
127  };
128 
129 
130 }
Diagonal crossing liens.
Definition: DtTacticalGraphicUtilities.h:93
DtVirtualBaseClassCreator< DtDepthOfFieldDrawable > DtDepthOfFieldDrawableCreator
Definition: DtDepthOfFieldDrawable.h:51
const char * creatorTypeName< DtDepthOfFieldDrawable >(void)
template specialization for the creator (pass the class being created to the creatorTypeName template...
Definition: DtDepthOfFieldDrawable.h:56
DtDofParams myParams
parameters
Definition: DtDepthOfFieldDrawable.h:111
2 dimensional vector
int myMutableVrvDepthTexLoc
Definition: DtDepthOfFieldDrawable.h:120
double camFar
Definition: DtDepthOfFieldDrawable.h:36
int viewHeight
Definition: DtDepthOfFieldDrawable.h:44
float vrv_focalDepth
Definition: DtDepthOfFieldDrawable.h:40
A convenience class to represent an OpenGL Shader Program.
Definition: DtGlProgram.h:65
int myMutableVrvUseReverseZBufferLoc
Definition: DtDepthOfFieldDrawable.h:115
bool myMutableTapsDirty
are the taps needed to be re-sent to the GPU
Definition: DtDepthOfFieldDrawable.h:126
friend DtDepthOfFieldDrawableCreator
friended, to access constructor above
Definition: DtDepthOfFieldDrawable.h:70
Variadic templated creator class for defining a DtVirtualBaseClass creator that is automatically regi...
Definition: DtVirtualBaseClassCreator.h:22
Definition: DtPostProcessorDrawable.h:24
float vrv_focalRange
Definition: DtDepthOfFieldDrawable.h:41
double camNear
Definition: DtDepthOfFieldDrawable.h:35
#define DT_DLL_VRVPOSTPROCESSOR
Definition: vrvPostProcessor.h:19
This file contains the declaration of the class DtPostProcessorDrawable which is used for rendering p...
structure to exchange/communicate DOF field parameters
Definition: DtDepthOfFieldDrawable.h:33
int myMutableVrvFocalDepthLoc
Definition: DtDepthOfFieldDrawable.h:116
int myMutableVrvFilterTapsLoc
Definition: DtDepthOfFieldDrawable.h:119
Contains DLL export macros.
bool vrv_useReverseZBuffer
Definition: DtDepthOfFieldDrawable.h:39
int myMutableVrvFocalRangeLoc
Definition: DtDepthOfFieldDrawable.h:117
osg::ref_ptr< osg::Texture > myBaseTexture
Definition: DtDepthOfFieldDrawable.h:104
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
DtDofParams()
constructor
int viewWidth
Definition: DtDepthOfFieldDrawable.h:43
bool vrv_useAutofocus
Definition: DtDepthOfFieldDrawable.h:38
int myMutableVrvUseAutofocusLoc
locations of various shader parameters
Definition: DtDepthOfFieldDrawable.h:114
osg::ref_ptr< osg::Texture > myDepthTexture
Definition: DtDepthOfFieldDrawable.h:105
DtGlProgram * myMutableDofProgram
the program
Definition: DtDepthOfFieldDrawable.h:108
class used to render dof during the post processor camera draw
Definition: DtDepthOfFieldDrawable.h:60
int myMutableVrvzNearFarLoc
Definition: DtDepthOfFieldDrawable.h:118

Document ID: Generated on Mon Jun 20 00:38:30 EDT 2022 from SVN revision 244029
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)