VR-Forces 4.0.4 Class Documentation
include/vrvGraphics/DtProjected2DLineEffect.h
Go to the documentation of this file.
00001 /******************************************************************************
00002 ** Copyright (c) 2010 MAK Technologies, Inc.
00003 ** All rights reserved.
00004 ******************************************************************************/
00005 /******************************************************************************
00006 ** $RCSfile:  $ $Revision:  $ $State:  $
00007 ******************************************************************************/
00008 
00012 
00013 #pragma once
00014 
00015 #include <vrvGraphics/Dt2DEffect.h>
00016 
00017 namespace makVrv
00018 {
00022    class DT_DLL_VRVGRAPHICS DtProjected2DLineEffect : public Dt2DEffect
00023    {
00024    public:
00025 
00027       DtProjected2DLineEffect();
00028 
00030       virtual ~DtProjected2DLineEffect();
00031 
00033       virtual void setCamera(bool geocentric, float geocentricAlpha,
00034          const double position[3],const double projection[16]);
00035 
00036       //Set the number of groups.
00037       virtual void setGroupCount(unsigned int count);
00038 
00039       virtual void setVaryingAttributes( size_t stride,
00040          const VaryingAttributeAddress& positionAddress,
00041          const VaryingAttributeAddress& colorAddress,
00042          const VaryingAttributeAddress& offsetAddress,
00043          const VaryingAttributeAddress& directionAndLengthAddress );
00044 
00045       virtual void unsetVaryingAttributes();
00046 
00047    protected:
00048 
00049       virtual void updateUniformLocations();
00050       virtual void updateUniforms();
00051       virtual void getShaderSource(const char*& vs,const char*& fs,const char*& gs);
00052 
00053    protected:   
00054       int myUniform_CameraPos;   
00055       int myUniform_CameraMat;
00056       int myUniform_GroupCount;
00057       int myUniform_Sphere;
00058       int myUniform_OccludedAlpha;
00059 
00060 
00061       unsigned int myUnit;
00062       unsigned int myGroupCount;
00063       double myCameraPos[3];
00064       double myMatrix[16];
00065       bool myGeocentricFlag;
00066       float myGeocentricAlpha;
00067    };
00068 
00069 
00072    class DT_DLL_VRVGRAPHICS DtProjected2DLineEffectCreator : public DtEffectCreator
00073    {
00074    public:
00075 
00076       virtual DtEffect* create(CreateParameters* params = 0)
00077       {
00078          return new DtProjected2DLineEffect();
00079       }
00080    };
00081 }
00082 

Document ID: Generated on Fri Jun 29 16:33:32 EDT 2012 from SVN revision 116588
Copyright © 2005-2012 VT MÄK Inc. All Rights Reserved (www.mak.com)