Version 4.06, Added possibility of using three different search structures UG Hash and AABB
This commit is contained in:
parent
a66d132c9c
commit
283e6b822d
|
@ -0,0 +1,32 @@
|
|||
|
||||
VCGLib http://vcg.sf.net o o
|
||||
Visual and Computer Graphics Library o o
|
||||
_ O _
|
||||
Copyright(C) 2005-2006 \/)\/
|
||||
Visual Computing Lab http://vcg.isti.cnr.it /\/|
|
||||
ISTI - Italian National Research Council |
|
||||
\
|
||||
Metro 4.06 2005/10/03
|
||||
All rights reserved.
|
||||
|
||||
2005/10/03 Release 4.06
|
||||
Changed the core for distance computation.
|
||||
Current version uses the lib flexible search structures.
|
||||
Now the comparison can be done exploiting a static uniform grid,
|
||||
a hashed grid or a hierarchy of AA box.
|
||||
|
||||
2005/04/04 Release 4.05
|
||||
Added saving of Error Histogram
|
||||
|
||||
2005/01/26 Release 4.04
|
||||
Gcc compiling issues
|
||||
Moved to the library core the code for computing min distance froma a point to a mesh using a uniform grid.
|
||||
Slightly faster.
|
||||
|
||||
2005/01/03 Release 4.03
|
||||
Better ply compatibility, and improved error reporting
|
||||
|
||||
2004/11/29 Release 4.02
|
||||
removed bug in printing Hausdorf distance,
|
||||
removed bug in command line parsing,
|
||||
upgraded import mesh library to support off format
|
|
@ -24,6 +24,9 @@
|
|||
History
|
||||
|
||||
$Log: not supported by cvs2svn $
|
||||
Revision 1.16 2005/09/16 11:52:14 cignoni
|
||||
removed wrong %v in vertex number printing
|
||||
|
||||
Revision 1.15 2005/04/04 10:36:36 cignoni
|
||||
Release 4.05
|
||||
Added saving of Error Histogram
|
||||
|
@ -117,8 +120,10 @@ void Usage()
|
|||
" -c save a mesh with error as per-vertex colour and quality\n"\
|
||||
" -C # # Set the min/max values used for color mapping\n"\
|
||||
" -L Remove duplicated and unreferenced vertices before processing\n"\
|
||||
" -H write files with histograms of error distribution\n"\
|
||||
|
||||
" -h write files with histograms of error distribution\n"\
|
||||
" -G Use a static Uniform Grid as Search Structure (default)\n"\
|
||||
" -A Use an AxisAligned Bounding Box Tree as Search Structure\n"\
|
||||
" -H Use an Hashed Uniform Grid as Search Structure\n"\
|
||||
"\n"
|
||||
"Default options are to sample vertexes, edge and faces by taking \n"
|
||||
"a number of samples that is approx. 10x the face number.\n"
|
||||
|
@ -164,7 +169,7 @@ int main(int argc, char**argv)
|
|||
|
||||
// print program info
|
||||
printf("-------------------------------\n"
|
||||
" Metro V.4.05 \n"
|
||||
" Metro V.4.06 \n"
|
||||
" http://vcg.isti.cnr.it\n"
|
||||
" release date: "__DATE__"\n"
|
||||
"-------------------------------\n\n");
|
||||
|
@ -182,7 +187,7 @@ int main(int argc, char**argv)
|
|||
if(argv[i][0]=='-')
|
||||
switch(argv[i][1])
|
||||
{
|
||||
case 'H' : flags |= SamplingFlags::HIST; break;
|
||||
case 'h' : flags |= SamplingFlags::HIST; break;
|
||||
case 'v' : flags &= ~SamplingFlags::VERTEX_SAMPLING; break;
|
||||
case 'e' : flags &= ~SamplingFlags::EDGE_SAMPLING; break;
|
||||
case 'f' : flags &= ~SamplingFlags::FACE_SAMPLING; break;
|
||||
|
@ -202,12 +207,18 @@ int main(int argc, char**argv)
|
|||
case 'c': flags |= SamplingFlags::SAVE_ERROR; break;
|
||||
case 'L': CleaningFlag=true; break;
|
||||
case 'C': ColorMin=float(atof(argv[i+1])); ColorMax=float(atof(argv[i+2])); i+=2; break;
|
||||
case 'A': flags |= SamplingFlags::USE_AABB_TREE; printf("Using AABB Tree as search structure\n"); break;
|
||||
case 'G': flags |= SamplingFlags::USE_STATIC_GRID; printf("Using static uniform grid as search structure\n"); break;
|
||||
case 'H': flags |= SamplingFlags::USE_HASH_GRID; printf("Using hashed uniform grid as search structure\n"); break;
|
||||
default : printf(MSG_ERR_INVALID_OPTION, argv[i]);
|
||||
exit(0);
|
||||
}
|
||||
i++;
|
||||
}
|
||||
|
||||
if(!(flags & SamplingFlags::USE_HASH_GRID) && !(flags & SamplingFlags::USE_AABB_TREE) )
|
||||
flags |= SamplingFlags::USE_STATIC_GRID;
|
||||
|
||||
// load input meshes.
|
||||
OpenMesh(argv[1],S1);
|
||||
OpenMesh(argv[2],S2);
|
||||
|
|
|
@ -6,10 +6,9 @@
|
|||
Visual Computing Lab http://vcg.isti.cnr.it /\/|
|
||||
ISTI - Italian National Research Council |
|
||||
\
|
||||
Metro 4.05 04/05/2005
|
||||
Metro 4.06 2005/10/03
|
||||
All rights reserved.
|
||||
|
||||
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
|
@ -55,6 +54,8 @@ Note that the three methods described above are used to sample only the interior
|
|||
A different scheme is used to sample vertices and edges: vertices are sampled in the straightforward manner,
|
||||
while edges are sampled by uniformly interleaving samples along each edge.
|
||||
|
||||
Three different Spatial indexing structures can be used to find the closest point to a sample, a Statically Allocated Uniform Grid, a Hashed Uniform Grid and a Hierarchy of axis aligned bounding boxes.
|
||||
|
||||
--- Basic usage ---
|
||||
|
||||
Metro is a command-line tool which allows the user to select among different sampling schemes.
|
||||
|
@ -64,19 +65,21 @@ Usage: Metro file1 file2 [opts]
|
|||
|
||||
where "file1" and "file2" are the input meshes in PLY, OFF or STL format, and opts can be:
|
||||
|
||||
-v disable vertex sampling
|
||||
-e disable edge sampling
|
||||
-f disable face sampling
|
||||
-u does not ignore unreferred vertices and sample also unreferenced vertices
|
||||
(useful for sampling point clouds against meshes)
|
||||
-sx set the face sampling mode
|
||||
where x can be:
|
||||
-S0 montecarlo sampling
|
||||
-S1 subdivision sampling
|
||||
-S2 similar triangles sampling (Default)
|
||||
-n# set the required number of samples (overrides -a)
|
||||
-a# set the required number of samples per area unit (overrides -n)
|
||||
-c save computed error as vertex colour and quality in two ply files
|
||||
-C # # Set the min/max values used for color mapping (useful for taking snapshot with coherent color ramp)
|
||||
-L Remove duplicated and unreferenced vertices before processing to avoid
|
||||
-H write files with histograms of error distribution
|
||||
-v disable vertex sampling
|
||||
-e disable edge sampling
|
||||
-f disable face sampling
|
||||
-u ignore unreferred vertices
|
||||
-sx set the face sampling mode
|
||||
where x can be:
|
||||
-s0 montecarlo sampling
|
||||
-s1 subdivision sampling
|
||||
-s2 similar triangles sampling (Default)
|
||||
-n# set the required number of samples (overrides -A)
|
||||
-a# set the required number of samples per area unit (overrides -N)
|
||||
-c save a mesh with error as per-vertex colour and quality
|
||||
-C # # Set the min/max values used for color mapping
|
||||
-L Remove duplicated and unreferenced vertices before processing
|
||||
-h write files with histograms of error distribution
|
||||
-G Use a static Uniform Grid as Search Structure (default)
|
||||
-A Use an Axis Aligned Bounding Box Tree as Search Structure
|
||||
-H Use an Hashed Uniform Grid as Search Structure
|
Loading…
Reference in New Issue