Orthography lenght -> length
This commit is contained in:
parent
dfc9192715
commit
c059114300
|
@ -204,7 +204,7 @@ static void FlipDiag(FaceType &f){
|
|||
|
||||
|
||||
// given a vertex (i.e. a face and a wedge),
|
||||
// this function tells us how the totale edge lenght around a vertex would change
|
||||
// this function tells us how the totale edge length around a vertex would change
|
||||
// if that vertex is rotated
|
||||
static ScalarType EdgeLenghtVariationIfVertexRotated(const FaceType &f, int w0)
|
||||
{
|
||||
|
@ -239,7 +239,7 @@ static ScalarType EdgeLenghtVariationIfVertexRotated(const FaceType &f, int w0)
|
|||
}
|
||||
|
||||
// given a vertex (i.e. a face and a wedge),
|
||||
// this function tells us how the totale edge lenght around a vertex would change
|
||||
// this function tells us how the totale edge length around a vertex would change
|
||||
// if that vertex is rotated
|
||||
static ScalarType QuadQualityVariationIfVertexRotated(const FaceType &f, int w0)
|
||||
{
|
||||
|
|
|
@ -270,13 +270,13 @@ class Clustering
|
|||
// The init function Take two parameters
|
||||
// _size is the approximate total number of cells composing the grid surrounding the objects (usually a large number)
|
||||
// eg _size==1.000.000 means a 100x100x100 grid
|
||||
// _cellsize is the absolute lenght of the edge of the grid cell.
|
||||
// _cellsize is the absolute length of the edge of the grid cell.
|
||||
// eg _cellsize==2.0 means that all the vertexes in a 2.0x2.0x2.0 cell are clustered togheter
|
||||
|
||||
// Notes:
|
||||
// _size is used only if the cell edge IS zero.
|
||||
// _cellsize gives you an absolute measure of the maximum error introduced
|
||||
// during the simplification (e.g. half of the cell edge lenght)
|
||||
// during the simplification (e.g. half of the cell edge length)
|
||||
|
||||
|
||||
void Init(Box3<ScalarType> _mbb, int _size, ScalarType _cellsize=0)
|
||||
|
|
|
@ -130,11 +130,11 @@ namespace vcg {
|
|||
if(!RayLineIntersection<SCALAR_TYPE>(line2,r,p_inters))
|
||||
return false;
|
||||
///then test if intersection point is nearest
|
||||
///to both extremes then lenght of the segment
|
||||
///to both extremes then length of the segment
|
||||
SCALAR_TYPE d0=(seg.P1()-p_inters).Norm();
|
||||
SCALAR_TYPE d1=(seg.P0()-p_inters).Norm();
|
||||
SCALAR_TYPE lenght=(seg.P0()-seg.P1()).Norm();
|
||||
return ((d0<lenght)&&(d1<lenght));
|
||||
SCALAR_TYPE length=(seg.P0()-seg.P1()).Norm();
|
||||
return ((d0<length)&&(d1<length));
|
||||
}
|
||||
|
||||
/// interseciton between point and triangle
|
||||
|
@ -152,11 +152,11 @@ namespace vcg {
|
|||
if(!LineLineIntersection(line,line2,p_inters))
|
||||
return false;
|
||||
///then test if intersection point is nearest
|
||||
///to both extremes then lenght of the segment
|
||||
///to both extremes then length of the segment
|
||||
SCALAR_TYPE d0=(seg.P1()-p_inters).Norm();
|
||||
SCALAR_TYPE d1=(seg.P0()-p_inters).Norm();
|
||||
SCALAR_TYPE lenght=(seg.P0()-seg.P1()).Norm();
|
||||
return ((d0<lenght)&&(d1<lenght));
|
||||
SCALAR_TYPE length=(seg.P0()-seg.P1()).Norm();
|
||||
return ((d0<length)&&(d1<length));
|
||||
}
|
||||
|
||||
/// interseciton between point and triangle
|
||||
|
|
|
@ -590,13 +590,13 @@ bool IntersectionSegmentTriangle( const vcg::Segment3<ScalarType> & seg,
|
|||
//first set both directions of ray
|
||||
vcg::Line3<ScalarType> line;
|
||||
vcg::Point3<ScalarType> dir;
|
||||
ScalarType lenght=seg.Length();
|
||||
ScalarType length=seg.Length();
|
||||
dir=(seg.P1()-seg.P0());
|
||||
dir.Normalize();
|
||||
line.Set(seg.P0(),dir);
|
||||
ScalarType orig_dist;
|
||||
if(IntersectionLineTriangle<ScalarType>(line,vert0,vert1,vert2,orig_dist,a,b))
|
||||
return (orig_dist<=lenght);
|
||||
return (orig_dist<=length);
|
||||
return false;
|
||||
}
|
||||
/**
|
||||
|
|
|
@ -127,7 +127,7 @@ public:
|
|||
/// returns segment length
|
||||
ScalarType Length() const
|
||||
{ return (_p0 - _p1).Norm(); }
|
||||
/// return segment squared lenght
|
||||
/// return segment squared length
|
||||
ScalarType SquaredLength() const
|
||||
{ return (_p0 - _p1).SquaredNorm(); }
|
||||
/// flips: a-b becomes b-a
|
||||
|
|
Loading…
Reference in New Issue