Index: /GTP/trunk/App/Demos/Vis/KdTreeDemo/OGRE/src/TestKdTreeAppListener.cpp
===================================================================
--- /GTP/trunk/App/Demos/Vis/KdTreeDemo/OGRE/src/TestKdTreeAppListener.cpp	(revision 1516)
+++ /GTP/trunk/App/Demos/Vis/KdTreeDemo/OGRE/src/TestKdTreeAppListener.cpp	(revision 2359)
@@ -512,7 +512,10 @@
 			(nodeVizMode == NODEVIZ_RENDER_NODES_AND_CONTENT);
 		bool renderNodesContentForViz = (nodeVizMode == NODEVIZ_RENDER_NODES_AND_CONTENT);
+		bool renderPvsForViz = nodeVizMode == NODEVIZ_RENDER_PVS;
 
 		mSceneMgr->setOption("RenderNodesForViz", &renderNodesForViz);
 		mSceneMgr->setOption("RenderNodesContentForViz", &renderNodesContentForViz);
+		mSceneMgr->setOption("RenderPvsForViz", &renderPvs);
+
 	}
 	else
Index: /GTP/trunk/App/Demos/Vis/HillyTerrain/OGRE/TerrainFrameListener.cpp
===================================================================
--- /GTP/trunk/App/Demos/Vis/HillyTerrain/OGRE/TerrainFrameListener.cpp	(revision 2352)
+++ /GTP/trunk/App/Demos/Vis/HillyTerrain/OGRE/TerrainFrameListener.cpp	(revision 2359)
@@ -487,6 +487,10 @@
 		//-- set parameters for visualization
 
-		// important for visualization => draw octree bounding boxes
-		if (0) mSceneMgr->setOption("ShowOctree", &mShowVisualization);
+		// draw octree bounding boxes because
+		// interesting for chc visualization
+		if (mNodeVizMode != NODEVIZ_RENDER_PVS) 
+		{
+			mSceneMgr->setOption("ShowOctree", &mShowVisualization);
+		}
 		
 		///////////////
@@ -506,6 +510,6 @@
 			-mCamera->getDerivedDirection().z));
 		
-		const float moveFactor = 200;
-		// move by a constant so view plane is on bottom of viewport
+		// move by a constant so view plane is on "bottom" of viewport
+        const float moveFactor = 1000;
 		mVizCamera->moveRelative(Vector3(0, moveFactor, 0));
 	}
@@ -1107,5 +1111,5 @@
 	if (pureRenderTime)
 	{
-		mPureRenderTimeFps = 1000.0 / (float) pureRenderTime;
+		mPureRenderTimeFps = 1000.0f / (float) pureRenderTime;
 	}
 	currentFps = mPureRenderRenderTimeFps;
@@ -1392,11 +1396,16 @@
 	mNodeVizMode = (mNodeVizMode + 1) % NODEVIZ_MODES_NUM;
 
-	bool renderNodesForViz = (mNodeVizMode == NODEVIZ_RENDER_NODES) || 
+	bool renderNodesForViz = 
+		(mNodeVizMode == NODEVIZ_RENDER_NODES) || 
 		(mNodeVizMode == NODEVIZ_RENDER_NODES_AND_CONTENT);
+
 	bool renderNodesContentForViz = (mNodeVizMode == NODEVIZ_RENDER_NODES_AND_CONTENT);
 	//bool renderNodesContentForViz = mNodeVizMode == NODEVIZ_RENDER_GEOMETRY;
 
+	bool renderPvsForViz = (mNodeVizMode == NODEVIZ_RENDER_PVS);
+
 	mSceneMgr->setOption("RenderNodesForViz", &renderNodesForViz);
 	mSceneMgr->setOption("RenderNodesContentForViz", &renderNodesContentForViz);
+	mSceneMgr->setOption("RenderPvsForViz", &renderPvsForViz);
 }
 //-----------------------------------------------------------------------
Index: /GTP/trunk/App/Demos/Vis/HillyTerrain/OGRE/TestCullingTerrainApplication.cpp
===================================================================
--- /GTP/trunk/App/Demos/Vis/HillyTerrain/OGRE/TestCullingTerrainApplication.cpp	(revision 2353)
+++ /GTP/trunk/App/Demos/Vis/HillyTerrain/OGRE/TestCullingTerrainApplication.cpp	(revision 2359)
@@ -419,7 +419,5 @@
 	mSunLight->setSpecularColour(1, 1, 1);
 
-	//-- Fog
-
-	// NB it's VERY important to set this before calling setWorldGeometry 
+	// it's VERY important to set fog before calling setWorldGeometry 
 	// because the vertex program picked will be different
 	ColourValue fadeColour(0.93, 0.86, 0.76);
@@ -474,7 +472,7 @@
 	{
 		// the objects are generated randomly distributed over the terrain
-		if (1) generateScene(500, 0); // create robots
-		if (0) generateScene(300, 1); // create ninjas
-		if (0) generateScene(1000, 2); // create trees
+		if (1) generateScene(1000, 0); // create robots
+		if (0) generateScene(100, 1); // create ninjas
+		if (1) generateScene(500, 2); // create trees
 	}
 	int MaxDepth=30;
@@ -649,10 +647,12 @@
 	// place on the ground object
 	if (success)
-			mCamNode->setPosition(
-				mCamNode->getPosition().x,
-				minVal + dist, 
-				mCamNode->getPosition().z);
+	{
+		mCamNode->setPosition(mCamNode->getPosition().x,
+							  minVal + dist, 
+							  mCamNode->getPosition().z);
+	}
 
 	OGRE_DELETE(raySceneQuery);
+
 	return success;
 }
Index: /GTP/trunk/App/Demos/Vis/HillyTerrain/OGRE/TerrainFrameListener.h
===================================================================
--- /GTP/trunk/App/Demos/Vis/HillyTerrain/OGRE/TerrainFrameListener.h	(revision 2352)
+++ /GTP/trunk/App/Demos/Vis/HillyTerrain/OGRE/TerrainFrameListener.h	(revision 2359)
@@ -164,7 +164,8 @@
    // visualization modes for scene nodes
    enum {
-		 NODEVIZ_NONE, 
-		 NODEVIZ_RENDER_NODES, 
-		 NODEVIZ_RENDER_NODES_AND_CONTENT, 
+		 NODEVIZ_NONE,
+         NODEVIZ_RENDER_NODES, 
+		 NODEVIZ_RENDER_NODES_AND_CONTENT,
+		 NODEVIZ_RENDER_PVS,
 		 NODEVIZ_MODES_NUM};
 
