Index: GTP/trunk/Lib/Vis/Preprocessing/src/ViewCellsManager.h
===================================================================
--- GTP/trunk/Lib/Vis/Preprocessing/src/ViewCellsManager.h	(revision 1603)
+++ GTP/trunk/Lib/Vis/Preprocessing/src/ViewCellsManager.h	(revision 1608)
@@ -534,4 +534,6 @@
   }
 
+  void UpdatePvsForEvaluation();
+
 protected:
 
Index: GTP/trunk/Lib/Vis/Preprocessing/src/QtGlRenderer.cpp
===================================================================
--- GTP/trunk/Lib/Vis/Preprocessing/src/QtGlRenderer.cpp	(revision 1594)
+++ GTP/trunk/Lib/Vis/Preprocessing/src/QtGlRenderer.cpp	(revision 1608)
@@ -998,4 +998,9 @@
 	  mWireFrame = true;
 	  RenderIntersectable(viewcell);
+	  glPushMatrix();
+	  glTranslatef(mViewPoint.x, mViewPoint.y, mViewPoint.z);
+	  gluSphere((::GLUquadric *)mSphere,
+				1e-3*Magnitude(mViewCellsManager->GetViewSpaceBox().Size()), 6, 6);
+	  glPopMatrix();
 	  mWireFrame = false;
 	}
@@ -1610,8 +1615,12 @@
 QtGlRendererWidget::SetViewCellGranularity(int number)
 {
-  if (mViewCellsManager) 
+  if (mViewCellsManager) {
 	//  	mViewCellsManager->SetMaxFilterSize(number);
     mViewCellsManager->CollectViewCells(number);
 
+	// $$ does not work so far:(
+	//	mViewCellsManager->UpdatePvsForEvaluation();
+	//	mViewCellsManager->FinalizeViewCells(false);
+  }
   updateGL();
 }
Index: GTP/trunk/Lib/Vis/Preprocessing/src/Preprocessor.cpp
===================================================================
--- GTP/trunk/Lib/Vis/Preprocessing/src/Preprocessor.cpp	(revision 1593)
+++ GTP/trunk/Lib/Vis/Preprocessing/src/Preprocessor.cpp	(revision 1608)
@@ -903,8 +903,8 @@
 		  }
 		if (i % 10000 == 0)
-		  cout<<i<<"/"<<rays.size()<<"\r";
-	}
-	
-
+		  cout<<"\r"<<i<<"/"<<rays.size()<<"\r";
+	}
+	cout<<endl;
+	
 	long t2 = GetTime();
 
Index: GTP/trunk/Lib/Vis/Preprocessing/src/default.env
===================================================================
--- GTP/trunk/Lib/Vis/Preprocessing/src/default.env	(revision 1594)
+++ GTP/trunk/Lib/Vis/Preprocessing/src/default.env	(revision 1608)
@@ -6,6 +6,8 @@
 Scene {
 
+#filename ../data/arena/export.obj
+
 # filename ../data/City4M/City4M.obj
-filename ../data/CityModel/CityModel.obj
+# filename ../data/CityModel/CityModel.obj
 # filename ../data/GrandCanyon/grandcanyon1_RotXmin90.obj
 # filename ../data/glasgow/glasgow1.x3d
@@ -14,10 +16,10 @@
 # filename ../data/vienna/vienna-buildings.x3d
 # filename ../data/vienna/city1500_flat_1.x3d
-filename ../data/vienna/vienna-buildings.x3d;../data/vienna/vienna-roofs.x3d;../data/vienna/vienna-roads.x3d
+#filename ../data/vienna/vienna-buildings.x3d;../data/vienna/vienna-roofs.x3d;../data/vienna/vienna-roads.x3d
 
 # ../data/vienna/vienna-plane.x3d;
 # filename ../data/vienna/viewcells-25-sel.x3d
 #filename ../data/atlanta/atlanta2.x3d
-#filename ../data/soda/soda.dat
+filename ../data/soda/soda.dat
 #filename ../data/test1/test2.x3d
 #filename ../data/soda/soda5.dat
@@ -53,4 +55,5 @@
 	applyVisibilitySpatialFilter false
 	visibilityFilterWidth	0.01
+	exportVisibility true
 	visibilityFile visibility.xml
 	loadMeshes false
@@ -76,5 +79,5 @@
 	samplesPerPass 1000
 	initialSamples 1000000
-	vssSamples 50000000
+	vssSamples 10000000
 	vssSamplesPerPass 1000000
 	useImportanceSampling true
@@ -145,5 +148,5 @@
 		minCost 4
 		maxDepth 30
-		maxCostRatio 0.99
+		maxCostRatio 1.0
 		ct_div_ci 0.5
 		maxNodes 300000
@@ -246,4 +249,6 @@
 	}
 
+#	filename ../data/arena/viewcells-5000.xml
+
 #	filename ../data/atlanta/atlanta_viewcells_large.x3d
 #	filename ../data/vienna/viewcells-25-sel.x3d
@@ -255,9 +260,12 @@
 #	filename ../data/soda/soda5-viewcells.xml
 #	filename ../scripts/viewcells_atlanta.xml
-#	filename ../data/soda/soda-viewcells-5000.xml
+	filename ../data/soda/soda-viewcells-5000.xml
 #	filename ../data/test1/test-viewcells.xml
 
 #	filename ../data/soda/soda5-viewcell-single.xm
 #	filename ../data/soda/soda-viewcells-1000.xml.zip
+#	filename ../data/soda/soda-viewcells-vsposp.xml
+
+
 #	filename ../data/CityModel/CityModel-viewcells-5000.xml
 #	filename ../data/City4M/City4M-viewcells-5000.xml
@@ -272,6 +280,10 @@
 #	filename ../data/vienna/vienna_simple-21-04-avs2-viewCells.xml
 #	filename ../data/vienna/vienna-viewcells-5000.xml
-	filename ../data/vienna/vienna-viewcells-1000.xml.zip
+#	filename ../data/vienna/vienna-viewcells-1000.xml.zip
 #	filename ../data/vienna/vsposp-seq-viewCells.xml.gz
+
+#	filename ../data/vienna/city1500_flat_viewcells-1000.xml
+#	filename ../data/vienna/city1500_flat-vsposp.xml
+#	filename ../data/vienna/vienna-simple-vsposp.xml
 
 #	filename ../data/PowerPlant/power_plant_viewcells1.xml
@@ -338,5 +350,5 @@
 #		minGlobalCostRatio      0.0001
 # $$MAXVIEWCELLS
-		maxViewCells		5000
+		maxViewCells		1000
 	
 
Index: GTP/trunk/Lib/Vis/Preprocessing/src/ViewCellsManager.cpp
===================================================================
--- GTP/trunk/Lib/Vis/Preprocessing/src/ViewCellsManager.cpp	(revision 1606)
+++ GTP/trunk/Lib/Vis/Preprocessing/src/ViewCellsManager.cpp	(revision 1608)
@@ -30,6 +30,6 @@
 
 // $$JB HACK
-#define USE_KD_PVS 1
-#define KD_PVS_AREA 1e-3f
+#define USE_KD_PVS 0
+#define KD_PVS_AREA 1e-4f
 
 namespace GtpVisibilityPreprocessor {
@@ -2472,4 +2472,11 @@
 
 
+void
+ViewCellsManager::UpdatePvsForEvaluation()
+{
+  ObjectPvs objPvs;
+  UpdatePvsForEvaluation(mViewCellsTree->GetRoot(), objPvs);
+}
+
 void ViewCellsManager::UpdatePvsForEvaluation(ViewCell *root, ObjectPvs &pvs)
 {
Index: GTP/trunk/Lib/Vis/Preprocessing/src/GlRenderer.cpp
===================================================================
--- GTP/trunk/Lib/Vis/Preprocessing/src/GlRenderer.cpp	(revision 1594)
+++ GTP/trunk/Lib/Vis/Preprocessing/src/GlRenderer.cpp	(revision 1608)
@@ -284,4 +284,6 @@
 GlRenderer::InitGL()
 {
+  mSphere = (GLUquadric *)gluNewQuadric();
+  
   glMatrixMode(GL_PROJECTION);
   glLoadIdentity();
Index: GTP/trunk/Lib/Vis/Preprocessing/src/Makefile
===================================================================
--- GTP/trunk/Lib/Vis/Preprocessing/src/Makefile	(revision 1594)
+++ GTP/trunk/Lib/Vis/Preprocessing/src/Makefile	(revision 1608)
@@ -1,5 +1,5 @@
 #############################################################################
 # Makefile for building: preprocessor
-# Generated by qmake (2.00a) (Qt 4.1.2) on: po 9. X 21:25:05 2006
+# Generated by qmake (2.00a) (Qt 4.1.2) on: út 10. X 22:38:46 2006
 # Project:  preprocessor.pro
 # Template: app
Index: GTP/trunk/Lib/Vis/Preprocessing/src/GlRenderer.h
===================================================================
--- GTP/trunk/Lib/Vis/Preprocessing/src/GlRenderer.h	(revision 1594)
+++ GTP/trunk/Lib/Vis/Preprocessing/src/GlRenderer.h	(revision 1608)
@@ -29,4 +29,6 @@
 struct VssRayContainer;
 
+  struct GLUquadric;
+  
 struct PvsRenderStatistics {
   
@@ -171,4 +173,6 @@
   string mSnapPrefix;
 
+  GLUquadric *mSphere;
+  
   KdTree *mKdTree;
 
