Index: GTP/trunk/App/Demos/Vis/FriendlyCulling/src/shaderenv.h
===================================================================
--- GTP/trunk/App/Demos/Vis/FriendlyCulling/src/shaderenv.h	(revision 3017)
+++ GTP/trunk/App/Demos/Vis/FriendlyCulling/src/shaderenv.h	(revision 3079)
@@ -10,6 +10,6 @@
 
 // for quadratic falloff
-#define SAMPLE_INTENSITY 0.1f
-//#define SAMPLE_INTENSITY 0.2f
+//#define SAMPLE_INTENSITY 0.1f
+#define SAMPLE_INTENSITY 0.07f
 
 #define SAMPLE_RADIUS 8e-1f
@@ -44,8 +44,10 @@
 #define WHITE_LUMINANCE 3e4f
 
+
 ///////////////////
 
 #define NUM_DOWNSAMPLES 16
 
+#define NUM_SSAO_FILTERSAMPLES 100
 
 #endif // __SHADERENV_H
Index: GTP/trunk/App/Demos/Vis/FriendlyCulling/src/shaders/ssao.cg
===================================================================
--- GTP/trunk/App/Demos/Vis/FriendlyCulling/src/shaders/ssao.cg	(revision 3034)
+++ GTP/trunk/App/Demos/Vis/FriendlyCulling/src/shaders/ssao.cg	(revision 3079)
@@ -236,6 +236,6 @@
 float Filter(float2 texCoord, 
 			 uniform sampler2D ssaoTex,
-			 uniform float2 filterOffs[NUM_DOWNSAMPLES],
-			 uniform float filterWeights[NUM_DOWNSAMPLES]
+			 uniform float2 filterOffs[NUM_SSAO_FILTERSAMPLES],
+			 uniform float filterWeights[NUM_SSAO_FILTERSAMPLES]
 )
 {
@@ -243,5 +243,5 @@
 	float w = .0f;
 
-	for (int i = 0; i < NUM_DOWNSAMPLES; ++ i)
+	for (int i = 0; i < NUM_SSAO_FILTERSAMPLES; ++ i)
 	{
 		average += filterWeights[i] * tex2Dlod(ssaoTex, float4(texCoord + filterOffs[i], 0, 0)).x;
@@ -258,6 +258,6 @@
 			  uniform sampler2D colors,
 			  uniform sampler2D ssaoTex,
-			  uniform float2 filterOffs[NUM_DOWNSAMPLES],
-			  uniform float filterWeights[NUM_DOWNSAMPLES]
+			  uniform float2 filterOffs[NUM_SSAO_FILTERSAMPLES],
+			  uniform float filterWeights[NUM_SSAO_FILTERSAMPLES]
 			  )
 {
@@ -267,6 +267,6 @@
 	float3 ao = tex2Dlod(ssaoTex, float4(IN.texCoord, 0, 0));
 
-	//if (ao.y < 2000.0f) 
-	//	ao.x = Filter(IN.texCoord, ssaoTex, filterOffs, filterWeights);
+	if (ao.y < 10.0f) 
+		ao.x = Filter(IN.texCoord, ssaoTex, filterOffs, filterWeights);
 
 	OUT.illum_col = col * ao.x;
Index: GTP/trunk/App/Demos/Vis/FriendlyCulling/src/chcdemo.cpp
===================================================================
--- GTP/trunk/App/Demos/Vis/FriendlyCulling/src/chcdemo.cpp	(revision 3078)
+++ GTP/trunk/App/Demos/Vis/FriendlyCulling/src/chcdemo.cpp	(revision 3079)
@@ -458,5 +458,5 @@
 	//-- load some dynamic stuff
 
-	LoadModel("hbuddha.dem", dynamicObjects);
+	/*LoadModel("hbuddha.dem", dynamicObjects);
 	buddha = dynamicObjects.back();
 	
@@ -480,5 +480,5 @@
 		ent->SetTransform(transform);
 		dynamicObjects.push_back(ent);
-	}
+	}*/
 
 
@@ -880,5 +880,5 @@
 
 	Matrix4x4 mat = TranslationMatrix(planepos);
-	buddha->GetTransform()->SetMatrix(mat);
+	//buddha->GetTransform()->SetMatrix(mat);
 
 	Vector3 oldPos = camera->GetPosition();
@@ -942,7 +942,5 @@
 
 		glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
-
 		glEnableClientState(GL_NORMAL_ARRAY);
-
 		break;
 
@@ -963,6 +961,4 @@
 		// (should be handled by render state)
 		glShadeModel(GL_FLAT);
-
-
 		break;
 
@@ -978,6 +974,4 @@
 		// (should be handled by render state)
 		glShadeModel(GL_FLAT);
-		
-
 		break;
 	
@@ -994,5 +988,4 @@
 		glEnableClientState(GL_NORMAL_ARRAY);
 		glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
-
 		break;
 	}
@@ -1019,9 +1012,7 @@
 	}
 	else
-	{glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
+	{
 		// actually render the scene geometry using the specified algorithm
 		traverser->RenderScene();
-		//for (int i = 0; i < sceneEntities.size(); ++ i)
-		//	sceneEntities[i]->Render(&state);
 	}
 
Index: GTP/trunk/App/Demos/Vis/FriendlyCulling/src/DeferredRenderer.cpp
===================================================================
--- GTP/trunk/App/Demos/Vis/FriendlyCulling/src/DeferredRenderer.cpp	(revision 3068)
+++ GTP/trunk/App/Demos/Vis/FriendlyCulling/src/DeferredRenderer.cpp	(revision 3079)
@@ -732,14 +732,15 @@
 	glDrawBuffers(1, mrt + colorBufferIdx);
 
-	float filterOffsets[NUM_DOWNSAMPLES * 2];
-	float filterWeights[NUM_DOWNSAMPLES];
-
-	PoissonDiscSampleGenerator2 poisson(NUM_DOWNSAMPLES, 1.0f);
+	float filterOffsets[NUM_SSAO_FILTERSAMPLES * 2];
+	float filterWeights[NUM_SSAO_FILTERSAMPLES];
+
+	PoissonDiscSampleGenerator2 poisson(NUM_SSAO_FILTERSAMPLES, 1.0f);
 	poisson.Generate((float *)filterOffsets);
 
-	const float xoffs = 2.0f / fbo->GetWidth();
-	const float yoffs = 2.0f / fbo->GetHeight();
-
-	for (int i = 0; i < NUM_DOWNSAMPLES; ++ i)
+	const float filterWidth = 10.0f;
+	const float xoffs = filterWidth / fbo->GetWidth();
+	const float yoffs = filterWidth / fbo->GetHeight();
+
+	for (int i = 0; i < NUM_SSAO_FILTERSAMPLES; ++ i)
 	{
 		float x = filterOffsets[2 * i + 0];
@@ -756,6 +757,6 @@
 	sCgCombineSsaoProgram->SetTexture(1, ssaoTex);
 
-	sCgCombineSsaoProgram->SetArray2f(2, (float *)filterOffsets, NUM_DOWNSAMPLES);
-	sCgCombineSsaoProgram->SetArray1f(3, (float *)filterWeights, NUM_DOWNSAMPLES);
+	sCgCombineSsaoProgram->SetArray2f(2, (float *)filterOffsets, NUM_SSAO_FILTERSAMPLES);
+	sCgCombineSsaoProgram->SetArray1f(3, (float *)filterWeights, NUM_SSAO_FILTERSAMPLES);
 	
 	DrawQuad(sCgCombineSsaoProgram);
