mirror of
https://github.com/CloudCompare/PoissonRecon.git
synced 2026-08-30 09:00:27 +08:00
Version 9.011
This commit is contained in:
+27
-1
@@ -115,6 +115,7 @@ void DumpOutput2( std::vector< char* >& comments , const char* format , ... )
|
||||
cmdLineString
|
||||
In( "in" ) ,
|
||||
Out( "out" ) ,
|
||||
TempDir( "tempDir" ) ,
|
||||
VoxelGrid( "voxel" ) ,
|
||||
XForm( "xForm" );
|
||||
|
||||
@@ -180,6 +181,7 @@ cmdLineReadable* params[] =
|
||||
&Color ,
|
||||
&NonLinearFit ,
|
||||
&PrimalVoxel ,
|
||||
&TempDir ,
|
||||
#if defined( _WIN32 ) || defined( _WIN64 )
|
||||
&Performance ,
|
||||
#endif // _WIN32 || _WIN64
|
||||
@@ -257,6 +259,8 @@ void ShowUsage( char* ex )
|
||||
printf( "\t[--%s <num threads>=%d]\n" , Threads.name , Threads.value );
|
||||
#endif // _OPENMP
|
||||
|
||||
printf( "\t[--%s]\n" , TempDir.name );
|
||||
|
||||
printf( "\t[--%s]\n" , Verbose.name );
|
||||
|
||||
#ifndef FOR_RELEASE
|
||||
@@ -580,7 +584,29 @@ int _Execute( int argc , char* argv[] )
|
||||
}
|
||||
}
|
||||
|
||||
CoredFileMeshData< Vertex > mesh;
|
||||
char tempHeader[1024];
|
||||
{
|
||||
#if defined( _WIN32 ) || defined( _WIN64 )
|
||||
const char FileSeparator = '\\';
|
||||
#else // !_WIN
|
||||
const char FileSeparator = '/';
|
||||
#endif // _WIN
|
||||
char tempPath[1024];
|
||||
tempPath[0] = 0;
|
||||
if( TempDir.set ) strcpy( tempPath , TempDir.value );
|
||||
else
|
||||
{
|
||||
#if defined( _WIN32 ) || defined( _WIN64 )
|
||||
GetTempPath( sizeof(tempPath) , tempPath );
|
||||
#else // !_WIN
|
||||
if( std::getenv( "TMPDIR" ) ) strcpy( tempPath , std::getenv( "TMPDIR" ) );
|
||||
#endif // _WIN
|
||||
}
|
||||
if( strlen(tempPath)==0 ) sprintf( tempPath , ".%c" , FileSeparator );
|
||||
if( tempPath[ strlen( tempPath )-1 ]==FileSeparator ) sprintf( tempHeader , "%sPR_" , tempPath );
|
||||
else sprintf( tempHeader , "%s%cPR_" , tempPath , FileSeparator );
|
||||
}
|
||||
CoredFileMeshData< Vertex > mesh( tempHeader );
|
||||
|
||||
{
|
||||
profiler.start();
|
||||
|
||||
Reference in New Issue
Block a user