Removed many small warnings

This commit is contained in:
Paolo Cignoni 2004-09-09 22:59:21 +00:00
parent 50b109625e
commit 542670453b
5 changed files with 21 additions and 25 deletions

View File

@ -24,6 +24,9 @@
History
$Log: not supported by cvs2svn $
Revision 1.6 2004/07/15 00:15:16 cignoni
inflate -> offset
Revision 1.5 2004/06/24 09:08:31 cignoni
Official Release of Metro 4.00
@ -143,7 +146,7 @@ void OpenMesh(const char *filename, CMesh &m)
int main(int argc, char**argv)
{
CMesh S1, S2;
double ColorMin=0, ColorMax=0;
float ColorMin=0, ColorMax=0;
double dist1_max, dist2_max;
unsigned long n_samples_target, elapsed_time;
double n_samples_per_area_unit;
@ -291,7 +294,7 @@ int main(int argc, char**argv)
// compute time info.
elapsed_time = clock() - t0;
int n_total_sample=ForwardSampling.GetNSamples()+BackwardSampling.GetNSamples();
float mesh_dist_max = max(dist1_max , dist2_max);
double mesh_dist_max = max(dist1_max , dist2_max);
printf("\nHausdorff distance: %f (%f with respect to bounding box diagonal)\n",(float)mesh_dist_max,(float)mesh_dist_max/bbox.Diag());
printf(" Computation time : %d ms\n", (int)elapsed_time);

View File

@ -24,6 +24,9 @@
History
$Log: not supported by cvs2svn $
Revision 1.11 2004/08/25 15:28:15 ponchio
Comma at end of enum.
Revision 1.10 2004/08/25 15:15:22 ganovelli
minor changes to comply gcc compiler (typename's and stuff)
@ -178,9 +181,9 @@ Sampling<MetroMesh>::Sampling(MetroMesh &_s1, MetroMesh &_s2):S1(_s1),S2(_s2)
area_S1 = ComputeMeshArea(_s1);
// set default numbers
n_samples_per_face = 10;
n_samples_edge_to_face_ratio = 0.1;
bbox_factor = 0.1;
inflate_percentage = 0.02;
n_samples_edge_to_face_ratio = 0.1f;
bbox_factor = 0.1f;
inflate_percentage = 0.02f;
min_size = 125; /* 125 = 5^3 */
n_hist_bins = 256;
print_every_n_elements = S1.fn/100;

View File

@ -131,6 +131,9 @@
Name="Header Files"
Filter="h;hpp;hxx;hm;inl;inc;xsd"
UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}">
<File
RelativePath="..\..\shadevis\gen_normal.h">
</File>
<File
RelativePath="..\..\..\vcg\math\similarity.h">
</File>

View File

@ -24,6 +24,9 @@
History
$Log: not supported by cvs2svn $
Revision 1.4 2004/09/09 22:37:48 cignoni
Integrated lost modifications...
Revision 1.3 2004/09/09 14:35:54 ponchio
Various changes for gcc compatibility
@ -45,25 +48,6 @@ Added GPL comments
#include "gen_normal.h"
namespace vcg {
template <class ScalarType>
void GenNormal(int vn, std::vector<Point3<ScalarType > > &NN)
{
typedef Point3<ScalarType> Point3x;
NN.clear();
while(NN.size()<vn)
{
Point3x pp(((float)rand())/RAND_MAX,
((float)rand())/RAND_MAX,
((float)rand())/RAND_MAX);
pp=pp*2.0-Point3x(1,1,1);
if(pp.SquaredNorm()<1)
{
Normalize(pp);
NN.push_back(pp);
}
}
}
// Base Class che definisce le varie interfaccie;
template <class MESH_TYPE, int MAXVIS=2048> class VisShader
{

View File

@ -24,6 +24,9 @@
History
$Log: not supported by cvs2svn $
Revision 1.8 2004/07/18 06:54:08 cignoni
Added Scaling
Revision 1.7 2004/07/11 22:06:56 cignoni
Added scaling by wheel
@ -61,7 +64,7 @@ void TrackMode::Apply(Trackball *trackball, float WheelNotch) {
}
void ScaleMode::Apply(Trackball *tb, Point3f new_point) {
float ScreenHeight= tb->camera.viewport[3]-tb->camera.viewport[1];
float ScreenHeight= float(tb->camera.viewport[3]-tb->camera.viewport[1]);
float dist=(new_point[1]-tb->last_point[1])/ScreenHeight;
tb->track.sca= tb->last_track.sca*pow(3.0f,-dist);
}