Changeset 2676 for GTP/trunk/Lib/Vis/Preprocessing/src
- Timestamp:
- 05/08/08 19:08:48 (17 years ago)
- Location:
- GTP/trunk/Lib/Vis/Preprocessing/src
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
GTP/trunk/Lib/Vis/Preprocessing/src/GtpVisibility05.vcproj
r2660 r2676 115 115 <Tool 116 116 Name="VCCLCompilerTool" 117 AdditionalIncludeDirectories="..\src;Timer;..\..\..\..\..\..\NonGTP\Devil\include;..\..\..\..\..\..\NonGTP\Zlib\include;"..\..\..\..\..\..\NonGTP\Xerces\xerces-c_2_8_0 -x86-windows-vc_8_0\include";..\..\..\..\..\..\NonGTP\Boost;..\src\havran;..\MultiLevelRayTracing;"$(CG_INC_PATH)""117 AdditionalIncludeDirectories="..\src;Timer;..\..\..\..\..\..\NonGTP\Devil\include;..\..\..\..\..\..\NonGTP\Zlib\include;"..\..\..\..\..\..\NonGTP\Xerces\xerces-c_2_8_0\include";..\..\..\..\..\..\NonGTP\Boost;..\src\havran;..\MultiLevelRayTracing;"$(CG_INC_PATH)"" 118 118 PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;USE_VERBOSE_PVS;USE_QT;GTP_INTERNAL;USE_CG" 119 119 RuntimeLibrary="2" -
GTP/trunk/Lib/Vis/Preprocessing/src/QtInterface/QtGlRenderer.cpp
r2671 r2676 69 69 #endif 70 70 71 void 72 QtGlRendererBuffer::MakeCurrent() 73 { 74 makeCurrent(); 75 } 76 77 void 78 QtGlRendererBuffer::DoneCurrent() 79 { 80 doneCurrent(); 71 72 void QtGlRendererBuffer::MakeCurrent() 73 { 74 QGLPixelBuffer::makeCurrent(); 75 //makeCurrent(); 76 } 77 78 79 void QtGlRendererBuffer::DoneCurrent() 80 { 81 QGLPixelBuffer::doneCurrent(); 82 //doneCurrent(); 81 83 } 82 84 -
GTP/trunk/Lib/Vis/Preprocessing/src/QtInterface/QtInterface05.vcproj
r2660 r2676 104 104 Name="VCCLCompilerTool" 105 105 WholeProgramOptimization="true" 106 AdditionalIncludeDirectories="..\src;..\..\src\;..\..\..\..\..\..\..\NonGTP\Zlib\include;"$(QTDIR)\include\QtOpenGL";"$(QTDIR)\include\Qt";"$(QTDIR)\include\QtGui";"$(QTDIR)\include\QtCore";"$(QTDIR)\include";"$(CG_INC_PATH)";"..\..\..\..\..\..\NonGTP\Xerces\xerces-c_2_8_0 -x86-windows-vc_8_0\include""106 AdditionalIncludeDirectories="..\src;..\..\src\;..\..\..\..\..\..\..\NonGTP\Zlib\include;"$(QTDIR)\include\QtOpenGL";"$(QTDIR)\include\Qt";"$(QTDIR)\include\QtGui";"$(QTDIR)\include\QtCore";"$(QTDIR)\include";"$(CG_INC_PATH)";"..\..\..\..\..\..\NonGTP\Xerces\xerces-c_2_8_0\include"" 107 107 PreprocessorDefinitions="WIN32;NDEBUG;_LIB;GTP_INTERNAL;USE_QT;USE_VERBOSE_PVS;USE_CG" 108 108 RuntimeLibrary="2" -
GTP/trunk/Lib/Vis/Preprocessing/src/TestPreprocessor05.vcproj
r2662 r2676 129 129 EnableFiberSafeOptimizations="false" 130 130 WholeProgramOptimization="true" 131 AdditionalIncludeDirectories="..\src;..\include;..\..\..\..\..\..\NonGTP\Boost;..\..\..\..\..\..\NonGTP\Devil\include;..\..\..\..\..\..\NonGTP\Zlib\include;"$(QTDIR)\include\QtOpenGl";"$(QTDIR)\include\Qt";"$(QTDIR)\include\QtCore";"$(QTDIR)\include";QtInterface;..\src\sparsehash\src\;..\src\ootl\src\include\ootl;..\src\ootl\src\include\ootl\sandbox; "..\..\..\..\..\..\NonGTP\Xerces\xerces-c_2_8_0-x86-windows-vc_8_0\include";$(NOINHERIT)"131 AdditionalIncludeDirectories="..\src;..\include;..\..\..\..\..\..\NonGTP\Boost;..\..\..\..\..\..\NonGTP\Devil\include;..\..\..\..\..\..\NonGTP\Zlib\include;"$(QTDIR)\include\QtOpenGl";"$(QTDIR)\include\Qt";"$(QTDIR)\include\QtCore";"$(QTDIR)\include";QtInterface;..\src\sparsehash\src\;..\src\ootl\src\include\ootl;..\src\ootl\src\include\ootl\sandbox;$(NOINHERIT)" 132 132 PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;GTP_INTERNAL;USE_QT;USE_CG;USE_VERBOSE_PVS" 133 133 StringPooling="true" … … 156 156 OutputFile="../bin/$(ConfigurationName)/Preprocessor.exe" 157 157 LinkIncremental="1" 158 AdditionalLibraryDirectories=""$(QTDIR)\lib";..\src\GL;"..\lib05\$(ConfigurationName)";..\..\..\..\..\..\NonGTP\Boost\lib;..\..\..\..\..\..\NonGTP\Zlib\lib;..\..\..\..\..\..\NonGTP\Devil\lib;"..\MultiLevelRayTracing\RTScene\$(ConfigurationName)";"..\MultiLevelRayTracing\RTWorld\$(ConfigurationName)";"QtInterface\$(ConfigurationName)";"..\..\..\..\..\..\NonGTP\Xerces\xerces-c_2_8_0 -x86-windows-vc_8_0\lib";"$(CG_LIB_PATH)""158 AdditionalLibraryDirectories=""$(QTDIR)\lib";..\src\GL;"..\lib05\$(ConfigurationName)";..\..\..\..\..\..\NonGTP\Boost\lib;..\..\..\..\..\..\NonGTP\Zlib\lib;..\..\..\..\..\..\NonGTP\Devil\lib;"..\MultiLevelRayTracing\RTScene\$(ConfigurationName)";"..\MultiLevelRayTracing\RTWorld\$(ConfigurationName)";"QtInterface\$(ConfigurationName)";"..\..\..\..\..\..\NonGTP\Xerces\xerces-c_2_8_0\lib";"$(CG_LIB_PATH)"" 159 159 GenerateDebugInformation="true" 160 160 SubSystem="1" -
GTP/trunk/Lib/Vis/Preprocessing/src/main.cpp
r2667 r2676 131 131 main(int argc, char **argv) 132 132 { 133 #if 0 134 // Test code by VH 135 TestRTcamera(argc, argv); 136 //TestRTfromFile(argc, argv); 137 //TestRTfromFilePackets(argc, argv); 138 //TestRT_4_fromFile(argc, argv); 139 return 0; 133 int returnCode = 0; 134 135 #ifdef _CRT_SET 136 137 //Now just call this function at the start of your program and if you're 138 //compiling in debug mode (F5), any leaks will be displayed in the Output 139 //window when the program shuts down. If you're not in debug mode this will 140 //be ignored. Use it as you will! 141 //note: from GDNet Direct [3.8.04 - 3.14.04] void detectMemoryLeaks() { 142 143 _CrtSetDbgFlag(_CRTDBG_LEAK_CHECK_DF|_CRTDBG_ALLOC_MEM_DF); 144 _CrtSetReportMode(_CRT_ASSERT,_CRTDBG_MODE_FILE); 145 _CrtSetReportFile(_CRT_ASSERT,_CRTDBG_FILE_STDERR); 140 146 #endif 141 cout<<"hello world"<<endl; 142 143 int returnCode = 0; 144 145 //Now just call this function at the start of your program and if you're 146 //compiling in debug mode (F5), any leaks will be displayed in the Output 147 //window when the program shuts down. If you're not in debug mode this will 148 //be ignored. Use it as you will! 149 //note: from GDNet Direct [3.8.04 - 3.14.04] void detectMemoryLeaks() { 150 151 //#define _CRT_SET 152 153 #ifdef _CRT_SET 154 _CrtSetDbgFlag(_CRTDBG_LEAK_CHECK_DF|_CRTDBG_ALLOC_MEM_DF); 155 _CrtSetReportMode(_CRT_ASSERT,_CRTDBG_MODE_FILE); 156 _CrtSetReportFile(_CRT_ASSERT,_CRTDBG_FILE_STDERR); 157 #endif 158 159 InitTiming(); 160 Debug.open("debug.log"); 161 162 Environment::GetSingleton()->Parse(argc, argv, USE_EXE_PATH); 163 MeshKdTree::ParseEnvironment(); 164 165 char buff[128]; 166 Environment::GetSingleton()->GetStringValue("Preprocessor.type", buff); 167 string preprocessorType(buff); 168 169 if (!(preprocessor = PreprocessorFactory::CreatePreprocessor(preprocessorType))) 147 148 InitTiming(); 149 Debug.open("debug.log"); 150 151 Environment::GetSingleton()->Parse(argc, argv, USE_EXE_PATH); 152 MeshKdTree::ParseEnvironment(); 153 154 char buff[128]; 155 Environment::GetSingleton()->GetStringValue("Preprocessor.type", buff); 156 string preprocessorType(buff); 157 158 if (!(preprocessor = PreprocessorFactory::CreatePreprocessor(preprocessorType))) 170 159 { 171 160 Environment::DelSingleton(); … … 174 163 } 175 164 176 165 177 166 Environment::GetSingleton()->GetStringValue("Scene.filename", buff); 178 167 string filename(buff); 179 168 180 169 const string externKdTree = ReplaceSuffix(filename, ".obj", ".kdf"); 181 170 const string internKdTree = GetInternFilename(filename, preprocessor->mLoadMeshes ? 182 171 ".kdm" : ".kdt"); 183 172 184 173 if (preprocessor->InitRayCast(externKdTree, internKdTree)) … … 193 182 } 194 183 195 196 //Debug << "using pvs type " << PVS_TYPE << endl;197 198 184 ///////////// 199 185 //-- load scene … … 205 191 exit(1); 206 192 } 207 193 208 194 209 195 //////////// … … 220 206 exit(1); 221 207 } 222 208 223 209 // export objects as obj 224 210 if (preprocessor->mExportObj) … … 231 217 else 232 218 { 233 219 234 220 const string objname = GetInternFilename(filename, ".obj"); 235 221 … … 237 223 bool success = preprocessor->ExportObj(objname, preprocessor->mObjects); 238 224 239 240 225 if (success) 241 226 cout << "finished exporting obj" << endl; … … 267 252 bool importRandomViewCells; 268 253 Environment::GetSingleton()->GetBoolValue("ViewCells.importRandomViewCells", 269 254 importRandomViewCells); 270 255 271 256 if (importRandomViewCells) … … 279 264 bool useHwGlobalLines; 280 265 Environment::GetSingleton()->GetBoolValue("Preprocessor.useHwGlobalLines", 281 266 useHwGlobalLines); 282 267 283 268 if (useHwGlobalLines) … … 286 271 // create a preprocessor thread (note: capsulates calls to boost fuctions!) 287 272 PreprocessorThread *pt = NULL; 288 273 289 274 //preprocessor->PrepareHwGlobalLines(); 290 275 //globalLinesRenderer->Run(); … … 306 291 QApplication *app = new QApplication(argc, NULL); 307 292 pt = new QtPreprocessorThread(preprocessor); 308 293 309 294 if (evalPixelError && (importRandomViewCells || frames)) 310 295 { … … 328 313 // $$matt 329 314 preprocessor->renderer = 330 331 332 333 334 315 new QtGlRendererBuffer(1024, 1024, 316 preprocessor->mSceneGraph, 317 preprocessor->mViewCellsManager, 318 preprocessor->mKdTree); 319 335 320 } 336 321 337 322 bool exportRandomViewCells; 338 323 Environment::GetSingleton()->GetBoolValue("ViewCells.exportRandomViewCells", 339 340 324 exportRandomViewCells); 325 341 326 if (exportRandomViewCells) 342 327 { … … 372 357 rendererWidget = 373 358 new QtGlRendererWidget(preprocessor->mSceneGraph, 374 375 359 preprocessor->mViewCellsManager, 360 preprocessor->mKdTree); 376 361 377 362 rendererWidget->Show(); … … 397 382 398 383 /*#if USE_THREADS 399 384 pt = new BoostPreprocessorThread(preprocessor); 400 385 #else 401 402 386 // use a dummy thread 387 pt = new DummyPreprocessorThread(preprocessor); 403 388 #endif 404 389 */
Note: See TracChangeset
for help on using the changeset viewer.