- Timestamp:
- 08/20/08 09:03:55 (16 years ago)
- Location:
- GTP/trunk/App/Demos/Vis/FriendlyCulling
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
GTP/trunk/App/Demos/Vis/FriendlyCulling/FriendlyCulling.vcproj
r2853 r2854 515 515 </File> 516 516 <File 517 RelativePath=".\src\FrameBufferObject.h" 518 > 519 </File> 520 <File 517 521 RelativePath=".\src\Geometry.h" 518 522 > … … 614 618 <File 615 619 RelativePath=".\src\chcdemo.cpp" 620 > 621 </File> 622 <File 623 RelativePath=".\src\FrameBufferObject.cpp" 616 624 > 617 625 </File> -
GTP/trunk/App/Demos/Vis/FriendlyCulling/src/LODInfo.h
r2853 r2854 16 16 struct LODLevel 17 17 { 18 //friend class SceneEntity;18 friend class SceneEntity; 19 19 20 20 public: … … 22 22 LODLevel(float squaredDist): mSquaredDistance(squaredDist) {} 23 23 24 inline float GetSquaredDistance() { return mSquaredDistance; }24 inline float GetSquaredDistance() const { return mSquaredDistance; } 25 25 26 inline int GetNumShapes() { return (int)mShapes.size(); }26 inline int GetNumShapes() const { return (int)mShapes.size(); } 27 27 28 inline int GetNumTriangles() { return mNumTriangles; }28 inline int GetNumTriangles() const { return mNumTriangles; } 29 29 30 inline Shape *GetShape(size_t i) { return mShapes[i]; }30 inline Shape *GetShape(size_t i) const { return mShapes[i]; } 31 31 32 32 inline ShapeContainer &GetShapes() { return mShapes; } … … 37 37 //////////////// 38 38 39 /** Has to be called each frame in order to use proper LOD level.39 /** Has to be called each frame in order to initialize the proper LOD level. 40 40 */ 41 41 static void InitFrame(const Vector3 &viewPoint); 42 42 43 43 44 protected: 45 46 static Vector3 sViewPoint; 47 /** The current frame id is used to update LOD. 48 */ 44 49 static int sFrameId; 45 static Vector3 sViewPoint;46 50 47 48 49 protected:50 51 51 52 ///////////////////// 52 53 53 float mNumTriangles;54 int mNumTriangles; 54 55 55 56 /// distance of this LOD level -
GTP/trunk/App/Demos/Vis/FriendlyCulling/src/RenderState.h
r2844 r2854 45 45 */ 46 46 void SetState(bool texturing, bool alphaTest, bool cullFace); 47 /** Returns wether we are inquery or render mode47 /** Returns either query or render mode 48 48 */ 49 49 inline Mode GetMode() const { return mMode; } … … 56 56 /** Returns the current vbo id. 57 57 */ 58 inline int GetCurrentVboId() { return mCurrentVboId; }58 inline int GetCurrentVboId() const { return mCurrentVboId; } 59 59 60 60 void SetRenderType(RenderType type) { mRenderType = type; } 61 RenderType GetRenderType() { return mRenderType; }61 RenderType GetRenderType() const { return mRenderType; } 62 62 63 63 64 64 /////////////////// 65 66 67 /////////////////// 68 //-- for deferred shading, we have to switch shaders on and off 65 69 66 70 static CGprofile sCgFragmentProfile; -
GTP/trunk/App/Demos/Vis/FriendlyCulling/src/chcdemo.cpp
r2853 r2854 405 405 InitGLstate(); 406 406 407 //glEnable(GL_MULTISAMPLE_ARB);408 //glHint(GL_MULTISAMPLE_FILTER_HINT_NV, GL_NICEST);407 glEnable(GL_MULTISAMPLE_ARB); 408 glHint(GL_MULTISAMPLE_FILTER_HINT_NV, GL_NICEST); 409 409 410 410 InitFBO(); -
GTP/trunk/App/Demos/Vis/FriendlyCulling/src/shaders/deferred.cg
r2853 r2854 111 111 112 112 113 /** Computes ambient occlusion + diffuse reflections 114 */ 113 115 float4 globIllum(fragment IN, 114 116 uniform sampler2D colors, … … 202 204 203 205 206 /** The mrt shader for screen space ambient occlusion 207 */ 204 208 pixel main_ssao(fragment IN, 205 209 uniform sampler2D colors, … … 268 272 269 273 274 /** The mrt shader for standard rendering 275 */ 270 276 pixel main(fragment IN, 271 277 uniform sampler2D colors,
Note: See TracChangeset
for help on using the changeset viewer.