VR-Forces 4.8 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
DtProjected2DLineEffect.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 2017 MAK Technologies, Inc.
3 ** All rights reserved.
4 ******************************************************************************/
5 /******************************************************************************
6 ** $RCSfile: $ $Revision: $ $State: $
7 ******************************************************************************/
8 
12 
13 #pragma once
14 
15 #include <vrvGraphics/Dt2DEffect.h>
16 
17 namespace makVrv
18 {
23  {
24  public:
25 
27  DtProjected2DLineEffect(const std::string& dataPath);
28 
30  virtual ~DtProjected2DLineEffect();
31 
33  virtual void setCamera(bool geocentric, float geocentricAlpha,
34  const double position[3]
35  , const double positionMatrix[16]
36  , const double projectionMatrix[16]);
37 
38  //Set the number of groups.
39  virtual void setGroupCount(unsigned int count);
40 
41  virtual void setVertexAttribPointers(size_t stride
42  , const VertexAttribPtrInfo& positionAddress
43  , const VertexAttribPtrInfo& colorAddress
44  , const VertexAttribPtrInfo& offsetAddress
45  , const VertexAttribPtrInfo& directionAndLengthAddress);
46 
47  virtual void unsetVertexAttribPointers();
48  protected:
49 
50  virtual void updateUniformLocations();
51  virtual void updateUniforms();
52  virtual void initializeShaderSource( void );
53 
54  protected:
61 
62 
63  unsigned int myUnit;
64  unsigned int myGroupCount;
65  double myCameraPos[3];
66  double myMatrix[16];
67  double myProjectionMatrix[16];
70 
71  void updateOtherUniforms(void);
72  };
73 
74 
78  {
79  public:
80  virtual DtEffect* create(const std::string& dataPath, CreateParameters* params = 0)
81  {
82  return new DtProjected2DLineEffect(dataPath);
83  }
84  };
85 }
86 
unsigned int myGroupCount
Definition: DtProjected2DLineEffect.h:64
Contains the makVrv::Dt2DEffect class declaration.
Abstract creator class for registering effects with a effects manager.
Definition: DtEffect.h:94
int myUniform_ProjectionMat
Definition: DtProjected2DLineEffect.h:57
float myGeocentricAlpha
Definition: DtProjected2DLineEffect.h:69
virtual DtEffect * create(const std::string &dataPath, CreateParameters *params=0)
Definition: DtProjected2DLineEffect.h:80
bool myGeocentricFlag
Definition: DtProjected2DLineEffect.h:68
A creator class for the Projected 2D line effect.
Definition: DtProjected2DLineEffect.h:77
int myUniform_CameraMat
Definition: DtProjected2DLineEffect.h:56
#define DT_DLL_VRVGRAPHICS
Contains DLL export macros.
Definition: vrvGraphics.h:19
int myUniform_Sphere
Definition: DtProjected2DLineEffect.h:59
Definition: DtEffect.h:23
The base class for a programmable pipeline render effect.
Definition: DtEffect.h:19
An effect for rendering 2D projected lines Has support for direction and length information per verte...
Definition: DtProjected2DLineEffect.h:22
unsigned int myUnit
Definition: DtProjected2DLineEffect.h:63
The 2D effect is an abstract interface for effects used to render in 2D.
Definition: Dt2DEffect.h:19
int myUniform_OccludedAlpha
Definition: DtProjected2DLineEffect.h:60
int myUniform_CameraPos
Definition: DtProjected2DLineEffect.h:55
int myUniform_GroupCount
Definition: DtProjected2DLineEffect.h:58

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)