Index: trunk/VUT/GtpVisibilityPreprocessor/src/Makefile
===================================================================
--- trunk/VUT/GtpVisibilityPreprocessor/src/Makefile	(revision 529)
+++ trunk/VUT/GtpVisibilityPreprocessor/src/Makefile	(revision 549)
@@ -1,5 +1,5 @@
 #############################################################################
 # Makefile for building: preprocessor
-# Generated by qmake (2.00a) (Qt 4.1.0) on: ?t 12. I 15:26:52 2006
+# Generated by qmake (2.00a) (Qt 4.1.0) on: po 16. I 20:32:45 2006
 # Project:  preprocessor.pro
 # Template: app
Index: trunk/VUT/GtpVisibilityPreprocessor/src/RssTree.cpp
===================================================================
--- trunk/VUT/GtpVisibilityPreprocessor/src/RssTree.cpp	(revision 537)
+++ trunk/VUT/GtpVisibilityPreprocessor/src/RssTree.cpp	(revision 549)
@@ -2088,7 +2088,10 @@
 	}
   }
-  
+
+  float extendedConvexCombinationProb = 0.0f; //0.7f
+  float silhouetteCheckPercentage = 0.0f; //0.5f
   for (int i=0; generated < numberOfRays && i < numberOfTries; i++) {
-	bool useExtendedConvexCombination = ((nrays >= 2) && (Random(1.0f) < 0.7f));
+	bool useExtendedConvexCombination = ((nrays >= 2) && (Random(1.0f) <
+														  extendedConvexCombinationProb));
 	
 	Vector3 origin, direction;
@@ -2163,5 +2166,5 @@
 	
 
-	if (i > numberOfRays/2) {
+	if (i > numberOfRays*(1.0f - silhouetteCheckPercentage)) {
 	  if (exporter) {
 		VssRay *ray = new VssRay(origin, origin + 100*direction, NULL, NULL);
Index: trunk/VUT/GtpVisibilityPreprocessor/src/RssPreprocessor.cpp
===================================================================
--- trunk/VUT/GtpVisibilityPreprocessor/src/RssPreprocessor.cpp	(revision 537)
+++ trunk/VUT/GtpVisibilityPreprocessor/src/RssPreprocessor.cpp	(revision 549)
@@ -13,5 +13,5 @@
 #include "GlRenderer.h"
 
-static bool useViewSpaceBox = true;
+static bool useViewSpaceBox = false;
 static bool use2dSampling = false;
 
@@ -82,4 +82,8 @@
 	
   SetupRay(ray, viewPoint, direction);
+
+  if (!mDetectEmptyViewSpace)
+	ray.mFlags &= ~Ray::CULL_BACKFACES;
+
   // cast ray to KD tree to find intersection with other objects
   Intersectable *objectA, *objectB;
@@ -101,12 +105,13 @@
   }
 
-  bool detectEmptyViewSpace = true;
-	
-  if (detectEmptyViewSpace) {
+
+  if (mDetectEmptyViewSpace) {
 	SetupRay(ray, pointA, -direction);
   } else
 	SetupRay(ray, viewPoint, -direction);
 	
-	
+  if (!mDetectEmptyViewSpace)
+	ray.mFlags &= ~Ray::CULL_BACKFACES;
+
   if (mKdTree->CastRay(ray)) {
 	objectB = ray.intersections[0].mObject;
@@ -122,5 +127,5 @@
 
   //  if (objectA == NULL && objectB != NULL) {
-  if (1) {
+  if (mDetectEmptyViewSpace) {
 	// cast again to ensure that there is no objectA
 	SetupRay(ray, pointB, direction);
@@ -135,12 +140,4 @@
 
   bool validSample = (objectA != objectB);
-  if (0 && detectEmptyViewSpace) {   // consider all samples valid
-	// check if the viewpoint lies on the line segment AB
-	if (Distance(pointA, pointB) <
-		Distance(viewPoint, pointA) + Distance(viewPoint, pointB) - Limits::Small) {
-	  validSample = false;
-	}
-  }
-	
   if (validSample) {
 	if (objectA) {
@@ -318,5 +315,7 @@
   //	exporter->ExportKdTree(*mKdTree);
   exporter->SetFilled();
-  exporter->ExportScene(mSceneGraph->mRoot);
+  // temporarily do not export the scene
+  if (0)
+	exporter->ExportScene(mSceneGraph->mRoot);
   exporter->SetWireframe();
 
Index: trunk/VUT/GtpVisibilityPreprocessor/src/default.env
===================================================================
--- trunk/VUT/GtpVisibilityPreprocessor/src/default.env	(revision 547)
+++ trunk/VUT/GtpVisibilityPreprocessor/src/default.env	(revision 549)
@@ -23,6 +23,6 @@
 	useGlRenderer true
 #	type sampling
-	type vss
-#	type rss
+#	type vss
+	type rss
 	detectEmptyViewSpace false
 }
@@ -70,7 +70,7 @@
 RssPreprocessor {
 	samplesPerPass  100000
-	initialSamples 500000
-	vssSamples 10000000
-	vssSamplesPerPass 500000
+	initialSamples 1000000
+	vssSamples 20000000
+	vssSamplesPerPass 1000000
 	useImportanceSampling true
 
@@ -87,5 +87,5 @@
 	useViewcells true
 	updateSubdivision true
-loadInitialSamples true
+	loadInitialSamples true
 	storeInitialSamples false
 }
@@ -107,8 +107,8 @@
 	maxStaticMemory	100
 
-	splitType regular
+#	splitType regular
 #	splitType heuristic
-#	splitType hybrid
-	splitUseOnlyDrivingAxis true
+	splitType hybrid
+	splitUseOnlyDrivingAxis false
 	importanceBasedCost false
 
@@ -168,5 +168,5 @@
 
 ViewCells {
-	loadFromFile false
+	loadFromFile true
 	#type kdTree
 	#type vspKdTree
@@ -200,5 +200,6 @@
 	}
 	
-	filename ../data/soda/viewcells_soda5.xml
+#	filename ../data/soda/viewcells_soda5.xml
+	filename ../data/atlanta/viewcells_atlanta2.xml
 #	filename ../data/atlanta/atlanta_viewcells_large.x3d
 #	filename ../data/vienna/viewcells-25-sel.x3d
Index: trunk/VUT/GtpVisibilityPreprocessor/src/preprocessor.pro
===================================================================
--- trunk/VUT/GtpVisibilityPreprocessor/src/preprocessor.pro	(revision 516)
+++ trunk/VUT/GtpVisibilityPreprocessor/src/preprocessor.pro	(revision 549)
@@ -44,4 +44,4 @@
 RenderSimulator.cpp VspKdTree.cpp RayInfo.cpp RssTree.cpp RssPreprocessor.cpp \
 ViewCellsManager.cpp VspBspTree.cpp GlRenderer.cpp \
-PreprocessorThread.cpp Renderer.cpp Beam.cpp ViewCellsParser.cpp
+PreprocessorThread.cpp Renderer.cpp Beam.cpp ViewCellsParser.cpp Tetrahedron3.cpp
 
