Index: /GTP/trunk/Lib/Vis/Preprocessing/src/QtInterface/QtGlRenderer.cpp
===================================================================
--- /GTP/trunk/Lib/Vis/Preprocessing/src/QtInterface/QtGlRenderer.cpp	(revision 2609)
+++ /GTP/trunk/Lib/Vis/Preprocessing/src/QtInterface/QtGlRenderer.cpp	(revision 2611)
@@ -109,5 +109,4 @@
 
 	ViewCell *viewcell = mViewCellsManager->GetViewCell(mViewPoint);
-	//  cout<<"View cell"<<viewcell<<endl;
 	if (viewcell == NULL)
 		return 0.0f;
Index: /GTP/trunk/Lib/Vis/Preprocessing/src/default.env
===================================================================
--- /GTP/trunk/Lib/Vis/Preprocessing/src/default.env	(revision 2610)
+++ /GTP/trunk/Lib/Vis/Preprocessing/src/default.env	(revision 2611)
@@ -518,5 +518,7 @@
 BSP {
   termCrit	  auto
+  # auto2 allows to set the number of primitives per leaf	
   #termCrit	  auto2
+  #adhoc allows to set maxdepth + number of primitives per leaf	
   #termCrit	  adhoc
   # For Arena
@@ -526,4 +528,7 @@
   #maxDepthAllowed 22
   #maxListLength    6
+  # For PowerPlant
+  maxDepthAllowed 18
+  maxListLength    8
   # For Power plant
   #maxDepthAllowed 8
Index: /GTP/trunk/Lib/Vis/Preprocessing/src/GlRenderer.cpp
===================================================================
--- /GTP/trunk/Lib/Vis/Preprocessing/src/GlRenderer.cpp	(revision 2609)
+++ /GTP/trunk/Lib/Vis/Preprocessing/src/GlRenderer.cpp	(revision 2611)
@@ -107,7 +107,8 @@
 		mPvsStatFrames = (int)mViewCellsManager->GetViewCellPointsList()->size();
 	else
-		Environment::GetSingleton()->GetIntValue("Preprocessor.pvsRenderErrorSamples", mPvsStatFrames);
-
-
+		Environment::GetSingleton()->GetIntValue("Preprocessor.pvsRenderErrorSamples",
+												 mPvsStatFrames);
+	
+	
 	mPvsErrorBuffer.resize(mPvsStatFrames);
 	ClearErrorBuffer();
@@ -1428,5 +1429,5 @@
   SetupProjection(GetWidth(), GetHeight());
 
-  cout<<"mPvsStatFrames="<<mPvsStatFrames<<endl;
+  cout<<"Random Pvs STATS, mPvsStatFrames="<<mPvsStatFrames<<endl;
   
   for (int i=0; i < mPvsStatFrames; i++) {
@@ -1434,5 +1435,7 @@
 	// set frame id for saving the error buffer
 	mFrame = i;
+	//	cerr<<"RV"<<endl;
 	RandomViewPoint();
+	//	cerr<<"RV2"<<endl;
 
  	if (mPvsErrorBuffer[i].mError == 1.0f) {
@@ -1461,6 +1464,10 @@
  	if (mPvsErrorBuffer[i].mError > 0.0f) {
 	  int pvsSize;
-	  
+
+	  cerr<<"GPE"<<endl;
+
 	  float error = GetPixelError(pvsSize);
+	  cerr<<"GPEd"<<endl;
+
 	  mPvsErrorBuffer[i].mError = error;
 	  mPvsErrorBuffer[i].mPvsSize = pvsSize;
Index: /GTP/trunk/Lib/Vis/Preprocessing/src/main.cpp
===================================================================
--- /GTP/trunk/Lib/Vis/Preprocessing/src/main.cpp	(revision 2610)
+++ /GTP/trunk/Lib/Vis/Preprocessing/src/main.cpp	(revision 2611)
@@ -293,4 +293,7 @@
 	Environment::GetSingleton()->GetIntValue("Preprocessor.pvsRenderErrorSamples", frames);
 
+	bool evalPixelError;
+	Environment::GetSingleton()->GetBoolValue("Preprocessor.evaluatePixelError", evalPixelError);
+
 #ifdef USE_QT
 
@@ -299,6 +302,7 @@
 	pt = new QtPreprocessorThread(preprocessor);	
 	
-	if (preprocessor->mUseGlRenderer && (importRandomViewCells || frames))
-
+	//	if (preprocessor->mUseGlRenderer && (importRandomViewCells || frames))
+
+	if (evalPixelError && (importRandomViewCells || frames))
 	  {
 		QGLFormat f;
Index: /GTP/trunk/Lib/Vis/Preprocessing/src/SG08/run_test_pixel
===================================================================
--- /GTP/trunk/Lib/Vis/Preprocessing/src/SG08/run_test_pixel	(revision 2610)
+++ /GTP/trunk/Lib/Vis/Preprocessing/src/SG08/run_test_pixel	(revision 2611)
@@ -4,5 +4,5 @@
 #COMMAND="./release/preprocessor.exe -preprocessor_quit_on_finish+"
 #COMMAND="../scripts/preprocessor.sh -preprocessor_quit_on_finish+ -preprocessor_use_gl_renderer- -preprocessor_evaluate_filter- -samples_per_pass=500000 -samples_per_evaluation=10000000 -total_samples=500000000 -preprocessor_pvs_rendererror_samples=10000 -preprocessor_evaluatePixelError+"
-COMMAND="../scripts/preprocessor.sh -preprocessor_quit_on_finish+ -preprocessor_use_gl_renderer+ -preprocessor_evaluate_filter- -samples_per_pass=1000000 -samples_per_evaluation=2000000 -total_samples=500000000 -preprocessor_pvs_rendererror_samples=10000 -preprocessor_evaluatePixelError+"
+COMMAND="../scripts/preprocessor.sh -preprocessor_quit_on_finish+ -preprocessor_use_gl_renderer- -preprocessor_evaluate_filter- -samples_per_pass=1000000 -samples_per_evaluation=500000 -total_samples=500000000 -preprocessor_pvs_rendererror_samples=10000 -preprocessor_evaluatePixelError+"
 
 #SCENE="../data/vienna/vienna-buildings.x3d;../data/vienna/vienna-roofs.x3d;../data/vienna/vienna-roads.x3d"
