Classes | Defines | Typedefs | Enumerations | Enumerator | Functions | Variables
Space

Classes

class  vcg::Box< N, S >
class  vcg::Box2< BoxScalarType >
class  vcg::Box3< BoxScalarType >
class  vcg::Color4< T >
class  vcg::ColorSpace< T >
class  vcg::Line2< LineScalarType, NORM >
class  vcg::Line3< LineScalarType, NORM >
class  vcg::Plane3< T, NORM >
class  vcg::ndim::Point< N, S >
class  vcg::ndim::Point2< S >
class  vcg::ndim::Point3< S >
class  vcg::ndim::Point4< S >
class  vcg::PointSegment2DEPFunctor< S >
class  vcg::Ray2< RayScalarType, NORM >
class  vcg::Ray3< RayScalarType, NORM >
class  vcg::RaySegmentIntersectionFunctor
class  vcg::RayTriangleIntersectionFunctor< BACKFACETEST >
class  vcg::Segment2< SegmentScalarType >
class  vcg::Segment3< SegmentScalarType >
struct  vcg::SmallestEnclosing
class  vcg::Sphere3< T >
class  vcg::Tetra
class  vcg::Tetra3< ScalarType >
class  vcg::TexCoord2< T, NMAX >
 Templated class for a storing a set of 2D texture coord plus their texture id. More...
class  vcg::TexCoord2Simple< T >
class  vcg::Triangle2< SCALAR_TYPE >
class  vcg::Triangle3< ScalarTriangleType >

Defines

#define ADD(dest, v1, v2)   dest[0]=v1[0]+v2[0]; dest[1]=v1[1]+v2[1]; dest[2]=v1[2]+v2[2];
#define COMPUTE_INTERVALS_ISECTLINE(VERT0, VERT1, VERT2, VV0, VV1, VV2, D0, D1, D2, D0D1, D0D2, isect0, isect1, isectpoint0, isectpoint1)
#define CROSS(dest, v1, v2)
#define DOT(v1, v2)   (v1[0]*v2[0]+v1[1]*v2[1]+v1[2]*v2[2])
#define DOT(v1, v2)   (v1[0]*v2[0]+v1[1]*v2[1]+v1[2]*v2[2])
#define EDGE_AGAINST_TRI_EDGES(V0, V1, U0, U1, U2)
#define EDGE_EDGE_TEST(V0, U0, U1)
#define FABS(x)   (T(fabs(x)))
#define MULT(dest, v, factor)   dest[0]=factor*v[0]; dest[1]=factor*v[1]; dest[2]=factor*v[2];
#define NEWCOMPUTE_INTERVALS(VV0, VV1, VV2, D0, D1, D2, D0D1, D0D2, A, B, C, X0, X1)
#define POINT_IN_TRI(V0, U0, U1, U2)
#define SET(dest, src)   dest[0]=src[0]; dest[1]=src[1]; dest[2]=src[2];
#define SORT(a, b)
#define SORT2(a, b, smallest)
#define SUB(dest, v1, v2)
#define TRI_TRI_INT_EPSILON   0.000001
#define USE_EPSILON_TEST

Typedefs

typedef Box< 2, double > vcg::Box2d
 Specificazione di box of double.
typedef Box< 2, float > vcg::Box2f
 Specificazione di box of float.
typedef Box< 2, int > vcg::Box2i
 Specificazione di box of int.
typedef Box< 2, short > vcg::Box2s
 Specificazione di box of short.
typedef Box< 3, double > vcg::Box3d
typedef Box< 3, float > vcg::Box3f
typedef Box< 3, int > vcg::Box3i
typedef Box< 3, short > vcg::Box3s
typedef Box3< ScalarTypevcg::Triangle3< ScalarTriangleType >::BoxType
 The bounding box type.
typedef Color4< unsigned char > vcg::Color4b
typedef Color4< double > vcg::Color4d
typedef Color4< float > vcg::Color4f
typedef Point2< ScalarTypevcg::Triangle2< SCALAR_TYPE >::CoordType
typedef Point3< ScalarTypevcg::Triangle3< ScalarTriangleType >::CoordType
typedef Line2< double > vcg::Line2d
typedef Line2< double, true > vcg::Line2dN
typedef Line2< float > vcg::Line2f
typedef Line2< float,true > vcg::Line2fN
typedef Line2< int > vcg::Line2i
typedef Line2< int,true > vcg::Line2iN
typedef Line2< short > vcg::Line2s
typedef Line2< short,true > vcg::Line2sN
typedef Line3< double > vcg::Line3d
typedef Line3< double, true > vcg::Line3dN
typedef Line3< float > vcg::Line3f
typedef Line3< float,true > vcg::Line3fN
typedef Line3< int > vcg::Line3i
typedef Line3< int,true > vcg::Line3iN
typedef Line3< short > vcg::Line3s
typedef Line3< short,true > vcg::Line3sN
typedef Plane3< double > vcg::Plane3d
typedef Plane3< float > vcg::Plane3f
typedef Point2< double > vcg::Point2d
typedef Point2< double > vcg::ndim::Point2d
typedef Point2< float > vcg::Point2f
typedef Point2< float > vcg::ndim::Point2f
typedef Point2< int > vcg::Point2i
typedef Point2< int > vcg::ndim::Point2i
typedef Point2< short > vcg::Point2s
typedef Point2< short > vcg::ndim::Point2s
typedef Point3< double > vcg::Point3d
typedef Point3< double > vcg::ndim::Point3d
typedef Point3< float > vcg::Point3f
typedef Point3< float > vcg::ndim::Point3f
typedef Point3< int > vcg::Point3i
typedef Point3< int > vcg::ndim::Point3i
typedef Point3< short > vcg::Point3s
typedef Point3< short > vcg::ndim::Point3s
typedef Point4< double > vcg::Point4d
typedef Point4< double > vcg::ndim::Point4d
typedef Point4< float > vcg::Point4f
typedef Point4< float > vcg::ndim::Point4f
typedef Point4< int > vcg::Point4i
typedef Point4< int > vcg::ndim::Point4i
typedef Point4< short > vcg::Point4s
typedef Point4< short > vcg::ndim::Point4s
typedef Point3< Tvcg::Plane3< T, NORM >::PointType
typedef Point2< SegmentScalarType > vcg::Segment2< SegmentScalarType >::PointType
 The point type.
typedef Point2< ScalarTypevcg::PointSegment2DEPFunctor< S >::QueryType
typedef Ray2< double > vcg::Ray2d
typedef Ray2< double, true > vcg::Ray2dN
typedef Ray2< float > vcg::Ray2f
typedef Ray2< float,true > vcg::Ray2fN
typedef Ray2< int > vcg::Ray2i
typedef Ray2< int,true > vcg::Ray2iN
typedef Ray2< short > vcg::Ray2s
typedef Ray2< short,true > vcg::Ray2sN
typedef Ray3< double > vcg::Ray3d
typedef Ray3< double, true > vcg::Ray3dN
typedef Ray3< float > vcg::Ray3f
typedef Ray3< float,true > vcg::Ray3fN
typedef Ray3< int > vcg::Ray3i
typedef Ray3< int,true > vcg::Ray3iN
typedef Ray3< short > vcg::Ray3s
typedef Ray3< short,true > vcg::Ray3sN
typedef SCALAR_TYPE vcg::Triangle2< SCALAR_TYPE >::ScalarType
typedef ScalarTriangleType vcg::Triangle3< ScalarTriangleType >::ScalarType
typedef T vcg::Plane3< T, NORM >::ScalarType
typedef SegmentScalarType vcg::Segment2< SegmentScalarType >::ScalarType
 The scalar type.
typedef T vcg::Sphere3< T >::ScalarType
typedef S vcg::PointSegment2DEPFunctor< S >::ScalarType
typedef Segment2< double > vcg::Segment2d
typedef Segment2< float > vcg::Segment2f
typedef Segment2< int > vcg::Segment2i
typedef Segment2< short > vcg::Segment2s
typedef Segment3< double > vcg::Segment3d
typedef Segment3< float > vcg::Segment3f
typedef Segment3< int > vcg::Segment3i
typedef Segment3< short > vcg::Segment3s
typedef Segment2
< SegmentScalarType > 
vcg::Segment2< SegmentScalarType >::SegmentType
 The point type.
typedef Sphere3< double > vcg::Sphere3d
typedef Sphere3< float > vcg::Sphere3f
typedef TexCoord2< double > vcg::TexCoord2d
typedef TexCoord2< float > vcg::TexCoord2f
typedef Triangle2< ScalarTypevcg::Triangle2< SCALAR_TYPE >::TriangleType
typedef Point2< double > vcg::ndim::Vector2d
typedef Point2< float > vcg::ndim::Vector2f
typedef Point2< int > vcg::ndim::Vector2i
typedef Point2< short > vcg::ndim::Vector2s
typedef Point3< double > vcg::ndim::Vector3d
typedef Point3< float > vcg::ndim::Vector3f
typedef Point3< int > vcg::ndim::Vector3i
typedef Point3< short > vcg::ndim::Vector3s
typedef Point4< double > vcg::ndim::Vector4d
typedef Point4< float > vcg::ndim::Vector4f
typedef Point4< int > vcg::ndim::Vector4i
typedef Point4< short > vcg::ndim::Vector4s

Enumerations

enum  vcg::ColorSpace< T >::ConeResponse { vcg::ColorSpace< T >::BRADFORD = 0, vcg::ColorSpace< T >::VON_KRIES = 1, vcg::ColorSpace< T >::XYZ_SCALING = 2 }
enum  vcg::ColorSpace< T >::Illuminant {
  vcg::ColorSpace< T >::VCG_ILLUMINANT_A = 0, vcg::ColorSpace< T >::VCG_ILLUMINANT_B = 1, vcg::ColorSpace< T >::VCG_ILLUMINANT_C = 2, vcg::ColorSpace< T >::VCG_ILLUMINANT_D50 = 3,
  vcg::ColorSpace< T >::VCG_ILLUMINANT_D55 = 4, vcg::ColorSpace< T >::VCG_ILLUMINANT_D65 = 5, vcg::ColorSpace< T >::VCG_ILLUMINANT_D75 = 6, vcg::ColorSpace< T >::VCG_ILLUMINANT_E = 7,
  vcg::ColorSpace< T >::VCG_ILLUMINANT_INVALID = 8
}
enum  vcg::ColorSpace< T >::RGBSpaces {
  vcg::ColorSpace< T >::ADOBE_RGB = 0, vcg::ColorSpace< T >::APPLE_RGB = 1, vcg::ColorSpace< T >::BEST_RGB = 2, vcg::ColorSpace< T >::BETA_RGB = 3,
  vcg::ColorSpace< T >::BRUCE_RGB = 4, vcg::ColorSpace< T >::CIE_RGB = 5, vcg::ColorSpace< T >::COLOR_MATCH = 6, vcg::ColorSpace< T >::DON_RGB4 = 7,
  vcg::ColorSpace< T >::ECI_RGB = 8, vcg::ColorSpace< T >::EKTA_SPACE = 9, vcg::ColorSpace< T >::NTSC_RGB = 10, vcg::ColorSpace< T >::PAL_RGB = 11,
  vcg::ColorSpace< T >::PROPHOTO = 12, vcg::ColorSpace< T >::SMPTE_C = 13, vcg::ColorSpace< T >::SRGB = 14, vcg::ColorSpace< T >::WIDE_GAMUT = 15
}

Functions

template<class SCALARTYPE >
Point2< SCALARTYPE > vcg::Abs (const Point2< SCALARTYPE > &p)
template<class SCALARTYPE >
Point3< SCALARTYPE > vcg::Abs (const Point3< SCALARTYPE > &p)
void vcg::Sphere3< T >::Add (const Point3< T > &p)
void vcg::Sphere3< T >::Add (const Sphere3 &sphere)
template<class T >
T vcg::Angle (Point2< T > const &p0, Point2< T > const &p1)
template<class T >
T vcg::Angle (const Point4< T > &p1, const Point4< T > &p2)
template<class P3ScalarType >
P3ScalarType vcg::Angle (Point3< P3ScalarType > const &p1, Point3< P3ScalarType > const &p2)
template<class S >
vcg::ndim::Angle (Point3< S > const &p1, Point3< S > const &p2)
template<class P3ScalarType >
P3ScalarType vcg::AngleN (Point3< P3ScalarType > const &p1, Point3< P3ScalarType > const &p2)
template<class S >
vcg::ndim::AngleN (Point3< S > const &p1, Point3< S > const &p2)
template<class P3ScalarType >
P3ScalarType vcg::ApproximateGeodesicDistance (const Point3< P3ScalarType > &p0, const Point3< P3ScalarType > &n0, const Point3< P3ScalarType > &p1, const Point3< P3ScalarType > &n1)
template<class TriangleType >
Point3< typename
TriangleType::ScalarType
vcg::Barycenter (const TriangleType &t)
template<class ScalarType >
Point3< ScalarTypevcg::Barycenter (const Tetra3< ScalarType > &t)
Box2< ScalarTypevcg::Segment2< SegmentScalarType >::BBox () const
 return the bounding box
static double vcg::ColorSpace< T >::CA (int index)
Point3< T > & vcg::Sphere3< T >::Center ()
const Point3< T > & vcg::Sphere3< T >::Center () const
static Color4< Tvcg::ColorSpace< T >::chromaticAdaptation (const Color4< T > &color, Illuminant src, Illuminant dst, ConeResponse response=BRADFORD)
static void vcg::ColorSpace< T >::chromaticAdaptation (double Xi, double Yi, double Zi, Illuminant src, double &X, double &Y, double &Z, Illuminant dst, ConeResponse response=BRADFORD)
static double vcg::ColorSpace< T >::CIE_EPSILON ()
static double vcg::ColorSpace< T >::CIE_KI ()
static Color4< Tvcg::ColorSpace< T >::CIELabtoXYZ (const Color4< T > &color, Illuminant ref)
static void vcg::ColorSpace< T >::CIELabtoXYZ (double L, double a, double b, double &X, double &Y, double &Z, Illuminant whiteRef)
template<class ScalarType >
bool vcg::CircleLineIntersection (const vcg::Line2< ScalarType > &line, const vcg::Point2< ScalarType > &center, const ScalarType &radius, vcg::Point2< ScalarType > &p0, vcg::Point2< ScalarType > &p1)
template<class TriangleType >
Point3< typename
TriangleType::ScalarType
vcg::Circumcenter (const TriangleType &t)
Color4< float > vcg::Clamp (Color4< float > &c)
template<class ScalarType >
Point2< ScalarTypevcg::ClosestPoint (Segment2< ScalarType > s, const Point2< ScalarType > &p)
template<class ScalarType , bool NORM>
Point2< ScalarTypevcg::ClosestPoint (Line2< ScalarType, NORM > l, const Point2< ScalarType > &p)
 returns closest point
template<class ScalarType , bool NORM>
Point2< ScalarTypevcg::ClosestPoint (Ray2< ScalarType, NORM > r, const Point2< ScalarType > &p)
 returns closest point
template<class ScalarType , bool NORM>
Point3< ScalarTypevcg::ClosestPoint (Ray3< ScalarType, NORM > r, const Point3< ScalarType > &p)
 returns closest point
template<class ScalarType , bool NORM>
Point3< ScalarTypevcg::ClosestPoint (Line3< ScalarType, NORM > l, const Point3< ScalarType > &p)
 returns closest point
template<class ScalarType >
Point2< ScalarTypevcg::ClosestPoint2Box2 (const Point2< ScalarType > &test, const Box2< ScalarType > &bbox)
template<class T >
int vcg::compute_intervals_isectline (Point3< T > VERT0, Point3< T > VERT1, Point3< T > VERT2, float VV0, float VV1, float VV2, float D0, float D1, float D2, float D0D1, float D0D2, float *isect0, float *isect1, Point3< T > &isectpoint0, Point3< T > &isectpoint1)
template<class TetraType >
TetraType::ScalarType vcg::ComputeVolume (const TetraType &t)
template<class Q >
static SegmentType vcg::Segment2< SegmentScalarType >::Construct (const Segment2< Q > &b)
 copy constructor (builds a new segment importing an existing one)
template<class SCALAR_TYPE >
bool vcg::Convex (const Point2< SCALAR_TYPE > &p0, const Point2< SCALAR_TYPE > &p1, const Point2< SCALAR_TYPE > &p2)
 return true if the algle is convex (right rotation)
template<class T >
bool vcg::coplanar_tri_tri (const Point3< T > N, const Point3< T > V0, const Point3< T > V1, const Point3< T > V2, const Point3< T > U0, const Point3< T > U1, const Point3< T > U2)
template<class TriangleType >
TriangleType::ScalarType vcg::CosWedge (const TriangleType &t, int k)
const CoordType & vcg::Triangle3< ScalarTriangleType >::cP (const int j) const
const CoordType & vcg::Triangle3< ScalarTriangleType >::cP0 (const int j) const
const CoordType & vcg::Triangle2< SCALAR_TYPE >::cP0 (const int j) const
const CoordType & vcg::Triangle3< ScalarTriangleType >::cP1 (const int j) const
const CoordType & vcg::Triangle2< SCALAR_TYPE >::cP1 (const int j) const
const CoordType & vcg::Triangle3< ScalarTriangleType >::cP2 (const int j) const
const CoordType & vcg::Triangle2< SCALAR_TYPE >::cP2 (const int j) const
int vcg::Sphere3< T >::CreateFromBox (int n, const Point3< T > *points)
int vcg::Sphere3< T >::CreateTight (int n, const Point3< T > *points, T threshold=1.01, T speed=0.6)
int vcg::Sphere3< T >::CreateTight (const std::vector< Point3< T > > &points, T threshold=1.01, T speed=0.6)
template<class ScalarType >
bool vcg::Cross (const Point2< ScalarType > &p00, const Point2< ScalarType > &p01, const Point2< ScalarType > &p10, const Point2< ScalarType > &p11)
template<class ScalarType , bool NORM>
ScalarType vcg::Distance (const Line2< ScalarType, NORM > &l, const Point2< ScalarType > &p)
template<class ScalarType , bool NORM>
ScalarType vcg::Distance (const Line3< ScalarType, NORM > &l, const Point3< ScalarType > &p)
template<class T >
T vcg::Distance (Point2< T > const &p1, Point2< T > const &p2)
template<class T >
T vcg::Distance (const Point4< T > &p1, const Point4< T > &p2)
template<class P3ScalarType >
P3ScalarType vcg::Distance (Point3< P3ScalarType > const &p1, Point3< P3ScalarType > const &p2)
template<int N, class S >
vcg::ndim::Distance (Point< N, S > const &p1, Point< N, S > const &p2)
template<class ScalarType >
ScalarType vcg::DistancePoint2Box2 (const Point2< ScalarType > &test, const Box2< ScalarType > &bbox)
template<class TriangleType >
TriangleType::ScalarType vcg::DoubleArea (const TriangleType &t)
 Return the Double of area of the triangle.
void vcg::Segment2< SegmentScalarType >::Flip ()
 flips: a-b becomes b-a
static double vcg::ColorSpace< T >::gamma (RGBSpaces rgb_space)
template<class P3ScalarType >
void vcg::GetUV (Point3< P3ScalarType > &n, Point3< P3ScalarType > &u, Point3< P3ScalarType > &v, Point3< P3ScalarType > up=(Point3< P3ScalarType >(0, 1, 0)))
static Color4< Tvcg::ColorSpace< T >::HSLtoRGB (const Color4< T > &color)
static void vcg::ColorSpace< T >::HSLtoRGB (double H, double S, double L, double &R, double &G, double &B)
static Color4< Tvcg::ColorSpace< T >::HSVtoRGB (const Color4< T > &color)
static void vcg::ColorSpace< T >::HSVtoRGB (double H, double S, double V, double &R, double &G, double &B)
static double vcg::ColorSpace< T >::Hue2RGB (double v1, double v2, double vH)
template<class Q >
void vcg::Segment2< SegmentScalarType >::Import (const Segment2< Q > &b)
 importer for different line types
bool vcg::Triangle2< SCALAR_TYPE >::InterpolationParameters (const CoordType &bq, ScalarType &L1, ScalarType &L2, ScalarType &L3) const
template<class TriangleType , class ScalarType >
bool vcg::InterpolationParameters (const TriangleType t, const int Axis, const Point3< ScalarType > &P, Point3< ScalarType > &L)
template<class TriangleType , class ScalarType >
bool vcg::InterpolationParameters (const TriangleType t, const Point3< ScalarType > &N, const Point3< ScalarType > &P, Point3< ScalarType > &L)
 Handy Wrapper of the above one that uses the passed normal N to choose the right orientation.
template<class TriangleType , class ScalarType >
bool vcg::InterpolationParameters (const TriangleType t, const Point3< ScalarType > &P, Point3< ScalarType > &L)
 Handy Wrapper of the above one that calculate the normal on the triangle.
template<class ScalarType >
bool vcg::InterpolationParameters2 (const Point2< ScalarType > &V1, const Point2< ScalarType > &V2, const Point2< ScalarType > &V3, const Point2< ScalarType > &P, Point3< ScalarType > &L)
template<class S >
bool vcg::Intersect (size_t cur, int v2, std::vector< int > &next, std::vector< Point2< S > > &points2)
void vcg::Sphere3< T >::Intersect (const Sphere3 &sphere)
template<class T >
bool vcg::IntersectionLineBox (const Box3< T > &box, const Line3< T > &r, Point3< T > &coord)
template<class T >
bool vcg::IntersectionLinePlane (const Line3< T > &li, const Plane3< T > &pl, Point3< T > &po)
 intersection between line and plane
template<class T >
bool vcg::IntersectionLineSphere (const Sphere3< T > &sp, const Line3< T > &li, Point3< T > &p0, Point3< T > &p1)
 interseciton between sphere and line
template<class T >
bool vcg::IntersectionLineTriangle (const Line3< T > &line, const Point3< T > &vert0, const Point3< T > &vert1, const Point3< T > &vert2, T &t, T &u, T &v)
template<class ScalarType >
bool vcg::IntersectionPlaneBox (const vcg::Plane3< ScalarType > &pl, vcg::Box3< ScalarType > &bbox)
template<class T >
bool vcg::IntersectionPlaneLine (const Plane3< T > &pl, const Line3< T > &li, Point3< T > &po)
 intersection between line and plane
template<class T >
bool vcg::IntersectionPlanePlane (const Plane3< T > &plane0, const Plane3< T > &plane1, Line3< T > &line)
template<class T >
bool vcg::IntersectionPlaneSegment (const Plane3< T > &pl, const Segment3< T > &s, Point3< T > &p0)
 intersection between segment and plane
template<class ScalarType >
bool vcg::IntersectionPlaneSegmentEpsilon (const Plane3< ScalarType > &pl, const Segment3< ScalarType > &sg, Point3< ScalarType > &po, const ScalarType epsilon=ScalarType(1e-8))
 intersection between segment and plane
template<typename TRIANGLETYPE >
bool vcg::IntersectionPlaneTriangle (const Plane3< typename TRIANGLETYPE::ScalarType > &pl, const TRIANGLETYPE &tr, Segment3< typename TRIANGLETYPE::ScalarType > &sg)
 intersection between plane and triangle
template<class T >
bool vcg::IntersectionRayBox (const Box3< T > &box, const Ray3< T > &r, Point3< T > &coord)
template<class T >
bool vcg::IntersectionRayTriangle (const Ray3< T > &ray, const Point3< T > &vert0, const Point3< T > &vert1, const Point3< T > &vert2, T &t, T &u, T &v)
template<class ScalarType >
bool vcg::IntersectionSegmentBox (const Box3< ScalarType > &box, const Segment3< ScalarType > &s, Point3< ScalarType > &coord)
template<class ScalarType >
int vcg::IntersectionSegmentBox (const Box3< ScalarType > &box, const Segment3< ScalarType > &s, Point3< ScalarType > &coord0, Point3< ScalarType > &coord1)
template<class SCALAR_TYPE >
int vcg::IntersectionSegmentSphere (const Sphere3< SCALAR_TYPE > &sphere, const Segment3< SCALAR_TYPE > &segment, Point3< SCALAR_TYPE > &t0, Point3< SCALAR_TYPE > &t1)
template<class ScalarType >
bool vcg::IntersectionSegmentTriangle (const vcg::Segment3< ScalarType > &seg, const Point3< ScalarType > &vert0, const Point3< ScalarType > &vert1, const Point3< ScalarType > &vert2, ScalarType &a, ScalarType &b)
template<class TriangleType >
bool vcg::IntersectionSegmentTriangle (const vcg::Segment3< typename TriangleType::ScalarType > &seg, const TriangleType &t, typename TriangleType::ScalarType &a, typename TriangleType::ScalarType &b)
template<class SphereType >
bool vcg::IntersectionSphereSphere (const SphereType &s0, const SphereType &s1)
template<class SCALAR_TYPE , class TRIANGLETYPE >
bool vcg::IntersectionSphereTriangle (const vcg::Sphere3< SCALAR_TYPE > &sphere, TRIANGLETYPE triangle, vcg::Point3< SCALAR_TYPE > &witness, std::pair< SCALAR_TYPE, SCALAR_TYPE > *res=NULL)
template<class ScalarType >
bool vcg::IntersectionTriangleBox (const vcg::Box3< ScalarType > &bbox, const vcg::Point3< ScalarType > &p0, const vcg::Point3< ScalarType > &p1, const vcg::Point3< ScalarType > &p2)
template<typename TRIANGLETYPE >
bool vcg::IntersectionTriangleTriangle (const TRIANGLETYPE &t0, const TRIANGLETYPE &t1)
 intersection between two triangles
template<class T >
bool vcg::IntersectionTriangleTriangle (Point3< T > V0, Point3< T > V1, Point3< T > V2, Point3< T > U0, Point3< T > U1, Point3< T > U2)
bool vcg::Triangle2< SCALAR_TYPE >::IsCCW ()
 retutn true if the face is contuerclockwise oriented
template<class T >
void vcg::isect2 (Point3< T > VTX0, Point3< T > VTX1, Point3< T > VTX2, float VV0, float VV1, float VV2, float D0, float D1, float D2, float *isect0, float *isect1, Point3< T > &isectpoint0, Point3< T > &isectpoint1)
bool vcg::Sphere3< T >::IsEmpty () const
bool vcg::Sphere3< T >::IsIn (const Point3< T > &p) const
 return true if
bool vcg::Sphere3< T >::IsIn (const Sphere3< T > &p) const
template<class SCALAR_TYPE >
bool vcg::IsInsideTrianglePoint (const Triangle2< SCALAR_TYPE > &t, const Point2< SCALAR_TYPE > &p)
 interseciton between point and triangle
ScalarType vcg::Segment2< SegmentScalarType >::Length ()
 returns segment length
ScalarType vcg::Segment2< SegmentScalarType >::Length () const
 returns segment length
PointType vcg::Segment2< SegmentScalarType >::Lerp (const ScalarType t) const
template<class SCALAR_TYPE >
bool vcg::LineLineIntersection (const vcg::Line2< SCALAR_TYPE > &l0, const vcg::Line2< SCALAR_TYPE > &l1, Point2< SCALAR_TYPE > &p)
template<class SCALAR_TYPE >
bool vcg::LineSegmentIntersection (const vcg::Line2< SCALAR_TYPE > &line, const vcg::Segment2< SCALAR_TYPE > &seg, Point2< SCALAR_TYPE > &p_inters)
 interseciton between point and triangle
template<class SCALARTYPE >
Point3< SCALARTYPE > vcg::LowClampToZero (const Point3< SCALARTYPE > &p)
PointType vcg::Segment2< SegmentScalarType >::MidPoint () const
 return the middle point
template<class ScalarType , bool NORM>
vcg::Point2< ScalarTypevcg::Mirror (const vcg::Line2< ScalarType, NORM > &l, const vcg::Point2< ScalarType > &p)
template<class T >
bool vcg::NoDivTriTriIsect (const Point3< T > V0, const Point3< T > V1, const Point3< T > V2, const Point3< T > U0, const Point3< T > U1, const Point3< T > U2)
template<class T >
T vcg::Norm (Point2< T > const &p)
template<class T >
T vcg::Norm (const Point4< T > &p)
template<class P3ScalarType >
P3ScalarType vcg::Norm (Point3< P3ScalarType > const &p)
template<int N, class S >
vcg::ndim::Norm (Point< N, S > const &p)
template<class Point3Type >
Point3Type vcg::Normal (Point3Type const &p0, Point3Type const &p1, Point3Type const &p2)
template<class TetraType >
Point3< typename
TetraType::ScalarType
vcg::Normal (const TetraType &t, const int &face)
 Returns the normal to the face face of the tetrahedron t.
template<class T >
Point2< T > & vcg::Normalize (Point2< T > &p)
template<class P3ScalarType >
Point3< P3ScalarType > & vcg::Normalize (Point3< P3ScalarType > &p)
template<int N, class S >
Point< N, S > & vcg::ndim::Normalize (Point< N, S > &p)
template<class TriangleType >
TriangleType::CoordType vcg::NormalizedTriangleNormal (const TriangleType &t)
 Returns the normal to the plane passing through p0,p1,p2.
bool vcg::Segment2< SegmentScalarType >::operator!= (SegmentType const &p) const
 Operator to dispare segments.
template<class EdgeType , class ScalarType >
bool vcg::PointSegment2DEPFunctor< S >::operator() (const EdgeType &e, const Point2< ScalarType > &p, ScalarType &minDist, Point2< ScalarType > &q)
template<class T >
Point2< Tvcg::operator* (const T s, Point2< T > const &p)
template<class T >
Point2< Tvcg::operator- (Point2< T > const &p)
bool vcg::Segment2< SegmentScalarType >::operator== (SegmentType const &p) const
 Operator to compare segments.
CoordType & vcg::Triangle3< ScalarTriangleType >::P (const int j)
 Shortcut per accedere ai punti delle facce.
CoordType & vcg::Triangle2< SCALAR_TYPE >::P (const int j)
 Shortcut per accedere ai punti delle facce.
const CoordType & vcg::Triangle3< ScalarTriangleType >::P (const int j) const
const CoordType & vcg::Triangle2< SCALAR_TYPE >::P (const int j) const
CoordType & vcg::Triangle3< ScalarTriangleType >::P0 (const int j)
CoordType & vcg::Triangle2< SCALAR_TYPE >::P0 (const int j)
const CoordType & vcg::Triangle3< ScalarTriangleType >::P0 (const int j) const
const PointTypevcg::Segment2< SegmentScalarType >::P0 () const
 Members to access either extrema.
const CoordType & vcg::Triangle2< SCALAR_TYPE >::P0 (const int j) const
PointTypevcg::Segment2< SegmentScalarType >::P0 ()
CoordType & vcg::Triangle3< ScalarTriangleType >::P1 (const int j)
CoordType & vcg::Triangle2< SCALAR_TYPE >::P1 (const int j)
const CoordType & vcg::Triangle3< ScalarTriangleType >::P1 (const int j) const
const PointTypevcg::Segment2< SegmentScalarType >::P1 () const
const CoordType & vcg::Triangle2< SCALAR_TYPE >::P1 (const int j) const
PointTypevcg::Segment2< SegmentScalarType >::P1 ()
CoordType & vcg::Triangle3< ScalarTriangleType >::P2 (const int j)
CoordType & vcg::Triangle2< SCALAR_TYPE >::P2 (const int j)
const CoordType & vcg::Triangle3< ScalarTriangleType >::P2 (const int j) const
const CoordType & vcg::Triangle2< SCALAR_TYPE >::P2 (const int j) const
template<class TriangleType >
TriangleType::ScalarType vcg::Perimeter (const TriangleType &t)
void vcg::Triangle2< SCALAR_TYPE >::PointDistance (const CoordType &q, ScalarType &dist, CoordType &p) const
 return the distance to the point q and neighors point p
template<class ScalarType >
bool vcg::PointInsidePolygon (vcg::Point2< ScalarType > p, const std::vector< vcg::Segment2< ScalarType > > &polygon)
static const Point2< ScalarType > & vcg::PointSegment2DEPFunctor< S >::Pos (const QueryType &qt)
template<class P3ScalarType >
P3ScalarType vcg::PSDist (const Point3< P3ScalarType > &p, const Point3< P3ScalarType > &v1, const Point3< P3ScalarType > &v2, Point3< P3ScalarType > &q)
 Point(p) Edge(v1-v2) dist, q is the point in v1-v2 with min dist.
template<class P3ScalarType >
P3ScalarType vcg::Quality (Point3< P3ScalarType > const &p0, Point3< P3ScalarType > const &p1, Point3< P3ScalarType > const &p2)
template<class TriangleType >
TriangleType::ScalarType vcg::QualityFace (const TriangleType &t)
 Return the _q of the face, the return value is in [0,sqrt(3)/2] = [0 - 0.866.. ].
template<class P3ScalarType >
P3ScalarType vcg::QualityMeanRatio (Point3< P3ScalarType > const &p0, Point3< P3ScalarType > const &p1, Point3< P3ScalarType > const &p2)
template<class P3ScalarType >
P3ScalarType vcg::QualityRadii (Point3< P3ScalarType > const &p0, Point3< P3ScalarType > const &p1, Point3< P3ScalarType > const &p2)
Tvcg::Sphere3< T >::Radius ()
const Tvcg::Sphere3< T >::Radius () const
template<class SCALAR_TYPE >
bool vcg::RayBoxIntersection (const vcg::Ray2< SCALAR_TYPE > &r, const vcg::Box2< SCALAR_TYPE > &bbox, Point2< SCALAR_TYPE > &p_inters)
 interseciton between point and triangle
template<class SCALAR_TYPE >
bool vcg::RayLineIntersection (const vcg::Line2< SCALAR_TYPE > &l, const vcg::Ray2< SCALAR_TYPE > &r, Point2< SCALAR_TYPE > &p)
template<class SCALAR_TYPE >
bool vcg::RaySegmentIntersection (const vcg::Ray2< SCALAR_TYPE > &r, const vcg::Segment2< SCALAR_TYPE > &seg, Point2< SCALAR_TYPE > &p_inters)
 interseciton between point and triangle
static Illuminant vcg::ColorSpace< T >::refIlluminant (RGBSpaces rgb_space)
static double vcg::ColorSpace< T >::RGB2XYZ (int index)
static Color4< Tvcg::ColorSpace< T >::RGBtoHSL (const Color4< T > &color)
static void vcg::ColorSpace< T >::RGBtoHSL (double R, double G, double B, double &H, double &S, double &L)
static Color4< Tvcg::ColorSpace< T >::RGBtoHSV (const Color4< T > &color)
static void vcg::ColorSpace< T >::RGBtoHSV (double R, double G, double B, double &H, double &S, double &V)
static Color4< Tvcg::ColorSpace< T >::RGBtoRGB (const Color4< T > &color, RGBSpaces rgbsrc, RGBSpaces rgbdest, ConeResponse response=BRADFORD)
static void vcg::ColorSpace< T >::RGBtoRGB (double Ri, double Gi, double Bi, RGBSpaces rgbsrc, double &R, double &G, double &B, RGBSpaces rgbdest, ConeResponse response=BRADFORD)
static Color4< Tvcg::ColorSpace< T >::RGBtoXYZ (const Color4< T > &color, RGBSpaces space, Illuminant dest, ConeResponse response=BRADFORD)
static void vcg::ColorSpace< T >::RGBtoXYZ (double R, double G, double B, RGBSpaces space, double &X, double &Y, double &Z, Illuminant dest, ConeResponse response=BRADFORD)
 vcg::Segment2< SegmentScalarType >::Segment2 ()
 The empty constructor.
 vcg::Segment2< SegmentScalarType >::Segment2 (const PointType &a, const PointType &b)
 The (a,b) constructor.
template<class SCALAR_TYPE >
bool vcg::SegmentSegmentIntersection (const vcg::Segment2< SCALAR_TYPE > &seg0, const vcg::Segment2< SCALAR_TYPE > &seg1, Point2< SCALAR_TYPE > &p_inters)
 interseciton between two segments
void vcg::Segment2< SegmentScalarType >::Set (const PointType &a, const PointType &b)
 initializes the segment with its extrema
template<class T >
T vcg::SignedDistancePlanePoint (const Plane3< T, true > &plane, const Point3< T > &point)
 Distance plane - point and vv. (Move these function to somewhere else)
template<class T >
T vcg::SignedDistancePointPlane (const Point3< T > &point, const Plane3< T, true > &plane)
 vcg::Sphere3< T >::Sphere3 ()
 vcg::Sphere3< T >::Sphere3 (const Point3< T > &center, T radius)
template<class T >
T vcg::SquaredDistance (Point2< T > const &p1, Point2< T > const &p2)
template<class T >
T vcg::SquaredDistance (const Point4< T > &p1, const Point4< T > &p2)
template<class P3ScalarType >
P3ScalarType vcg::SquaredDistance (Point3< P3ScalarType > const &p1, Point3< P3ScalarType > const &p2)
template<int N, class S >
vcg::ndim::SquaredDistance (Point< N, S > const &p1, Point< N, S > const &p2)
ScalarType vcg::Segment2< SegmentScalarType >::SquaredLength ()
 return segment squared length
template<class T >
T vcg::SquaredNorm (Point2< T > const &p)
template<class T >
T vcg::SquaredNorm (const Point4< T > &p)
template<class P3ScalarType >
P3ScalarType vcg::SquaredNorm (Point3< P3ScalarType > const &p)
template<int N, class S >
vcg::ndim::SquaredNorm (Point< N, S > const &p)
template<class P3ScalarType >
double vcg::stable_dot (Point3< P3ScalarType > const &p0, Point3< P3ScalarType > const &p1)
template<class T >
double vcg::StableDot (Point4< T > const &p0, Point4< T > const &p1)
 slower version of dot product, more stable (double precision only)
template<class POINT_CONTAINER >
void vcg::TessellatePlanarPolygon2 (POINT_CONTAINER &points2, std::vector< int > &output)
template<class POINT_CONTAINER >
void vcg::TessellatePlanarPolygon3 (POINT_CONTAINER &points, std::vector< int > &output)
template<class T >
bool vcg::tri_tri_intersect_with_isectline (Point3< T > V0, Point3< T > V1, Point3< T > V2, Point3< T > U0, Point3< T > U1, Point3< T > U2, bool &coplanar, Point3< T > &isectpt1, Point3< T > &isectpt2)
 vcg::Triangle2< SCALAR_TYPE >::Triangle2 ()
 vcg::Triangle2< SCALAR_TYPE >::Triangle2 (const CoordType &p0, const CoordType &p1, const CoordType &p2)
 vcg::Triangle3< ScalarTriangleType >::Triangle3 ()
 vcg::Triangle3< ScalarTriangleType >::Triangle3 (const CoordType &c0, const CoordType &c1, const CoordType &c2)
template<class TriangleType >
TriangleType::CoordType vcg::TriangleNormal (const TriangleType &t)
 Returns the normal to the plane passing through p0,p1,p2.
template<class ScalarType >
bool vcg::TriangleTriangleIntersect2D (const vcg::Triangle2< ScalarType > &tr0, const vcg::Triangle2< ScalarType > &tr1)
int vcg::Triangle3< ScalarTriangleType >::VN () const
static Color4< Tvcg::ColorSpace< T >::xyYtoXYZ (const Color4< T > &color)
static void vcg::ColorSpace< T >::xyYtoXYZ (double x, double y, double _Y, double &X, double &Y, double &Z)
static double vcg::ColorSpace< T >::XYZ2RGB (int index)
static Color4< Tvcg::ColorSpace< T >::XYZtoCIELab (const Color4< T > &color, Illuminant ref)
static void vcg::ColorSpace< T >::XYZtoCIELab (double X, double Y, double Z, double &L, double &a, double &b, Illuminant whiteRef)
static Color4< Tvcg::ColorSpace< T >::XYZtoRGB (const Color4< T > &color, Illuminant src, RGBSpaces dest, ConeResponse response=BRADFORD)
static void vcg::ColorSpace< T >::XYZtoRGB (double X, double Y, double Z, Illuminant src, double &R, double &G, double &B, RGBSpaces space, ConeResponse response=BRADFORD)
static Color4< Tvcg::ColorSpace< T >::XYZtoxyY (const Color4< T > &color)
static void vcg::ColorSpace< T >::XYZtoxyY (double X, double _Y, double Z, double &x, double &y, double &Y)

Variables

Point3< Tvcg::Sphere3< T >::_center
PointType vcg::Plane3< T, NORM >::_dir
 Direction (not necessarily normalized unless NORM is true)
ScalarType vcg::Plane3< T, NORM >::_offset
 Distance.
PointType vcg::Segment2< SegmentScalarType >::_p0
 _extrema
PointType vcg::Segment2< SegmentScalarType >::_p1
T vcg::Sphere3< T >::_radius
Point2< ScalarTypevcg::Triangle2< SCALAR_TYPE >::_v [3]
 Vector of vertex pointer incident in the face.
Point3< ScalarTypevcg::Triangle3< ScalarTriangleType >::_v [3]
 Vector of vertex pointer incident in the face.

Classical overloading of operators

Note

Box3< P3ScalarType > vcg::Point3< P3ScalarType >::GetBBox (Box3< P3ScalarType > &bb) const

Constructors

 vcg::Plane3< T, NORM >::Plane3 ()
 The empty constructor.
 vcg::Plane3< T, NORM >::Plane3 (const ScalarType &dist, const PointType &dir)
 The (distance, direction) constructor.
template<class Q >
void vcg::Plane3< T, NORM >::Import (const Plane3< Q, false > &b)

Members to access the distance or direction

Direction() cannot be assigned directly. Use SetDirection() or Set() instead. This is mandatory to make possible the automatic autonormalization template mechanism. Note that if you have to set both direction and offset it can be more efficient to set them toghether

const ScalarTypevcg::Plane3< T, NORM >::Offset () const
ScalarTypevcg::Plane3< T, NORM >::Offset ()
void vcg::Plane3< T, NORM >::SetOffset (const ScalarType &o)
 sets the origin
const PointTypevcg::Plane3< T, NORM >::Direction () const
void vcg::Plane3< T, NORM >::SetDirection (const PointType &dir)
 sets the direction
void vcg::Plane3< T, NORM >::Set (const ScalarType &off, const PointType &dir)
 sets origin and direction.
void vcg::Plane3< T, NORM >::Set (const PointType &dir, const ScalarType &off)
bool vcg::Plane3< T, NORM >::operator== (Plane3 const &p) const
 Operator to compare two lines.
bool vcg::Plane3< T, NORM >::operator!= (Plane3 const &p) const
 Operator to dispare two lines.
PointType vcg::Plane3< T, NORM >::Projection (const PointType &p) const
 Project a point on the plane.
PointType vcg::Plane3< T, NORM >::Mirror (const PointType &p) const
 Mirror the point wrt the plane.
void vcg::Plane3< T, NORM >::Normalize ()
 Function to normalize direction.
void vcg::Plane3< T, NORM >::Init (const PointType &p0, const PointType &p1, const PointType &p2)
 Calculates the plane passing through three points (Rename this method)
void vcg::Plane3< T, NORM >::Init (const PointType &p0, const PointType &norm)
 Calculates the plane passing through a point and the normal (Rename this method.

Linearity for 3d segments (operators +, -, *, /)

SegmentType vcg::Segment2< SegmentScalarType >::operator+ (SegmentType const &p) const
SegmentType vcg::Segment2< SegmentScalarType >::operator- (SegmentType const &p) const
SegmentType vcg::Segment2< SegmentScalarType >::operator* (const ScalarType s) const
SegmentType vcg::Segment2< SegmentScalarType >::operator/ (const ScalarType s) const

Define Documentation

#define ADD (   dest,
  v1,
  v2 
)    dest[0]=v1[0]+v2[0]; dest[1]=v1[1]+v2[1]; dest[2]=v1[2]+v2[2];

Definition at line 360 of file triangle_triangle3.h.

#define COMPUTE_INTERVALS_ISECTLINE (   VERT0,
  VERT1,
  VERT2,
  VV0,
  VV1,
  VV2,
  D0,
  D1,
  D2,
  D0D1,
  D0D2,
  isect0,
  isect1,
  isectpoint0,
  isectpoint1 
)
Value:
if(D0D1>0.0f)                                         \
  {                                                     \
    /* here we know that D0D2<=0.0 */                   \
    /* that is D0, D1 are on the same side, D2 on the other or on the plane */ \
    isect2(VERT2,VERT0,VERT1,VV2,VV0,VV1,D2,D0,D1,&isect0,&isect1,isectpoint0,isectpoint1);          \
  }

Definition at line 430 of file triangle_triangle3.h.

#define CROSS (   dest,
  v1,
  v2 
)
Value:
{                     \
              dest[0]=v1[1]*v2[2]-v1[2]*v2[1]; \
              dest[1]=v1[2]*v2[0]-v1[0]*v2[2]; \
              dest[2]=v1[0]*v2[1]-v1[1]*v2[0];}

Definition at line 57 of file triangle_triangle3.h.

#define DOT (   v1,
  v2 
)    (v1[0]*v2[0]+v1[1]*v2[1]+v1[2]*v2[2])

Definition at line 359 of file triangle_triangle3.h.

#define DOT (   v1,
  v2 
)    (v1[0]*v2[0]+v1[1]*v2[1]+v1[2]*v2[2])

Definition at line 359 of file triangle_triangle3.h.

#define EDGE_AGAINST_TRI_EDGES (   V0,
  V1,
  U0,
  U1,
  U2 
)
Value:
{                                              \
  T Ax,Ay,Bx,By,Cx,Cy,e,d,f;               \
  Ax=V1[i0]-V0[i0];                            \
  Ay=V1[i1]-V0[i1];                            \
  /* test edge U0,U1 against V0,V1 */          \
  EDGE_EDGE_TEST(V0,U0,U1);                    \
  /* test edge U1,U2 against V0,V1 */          \
  EDGE_EDGE_TEST(V0,U1,U2);                    \
  /* test edge U2,U1 against V0,V1 */          \
  EDGE_EDGE_TEST(V0,U2,U0);                    \
}

Definition at line 100 of file triangle_triangle3.h.

#define EDGE_EDGE_TEST (   V0,
  U0,
  U1 
)
Value:
Bx=U0[i0]-U1[i0];                                   \
  By=U0[i1]-U1[i1];                                   \
  Cx=V0[i0]-U0[i0];                                   \
  Cy=V0[i1]-U0[i1];                                   \
  f=Ay*Bx-Ax*By;                                      \
  d=By*Cx-Bx*Cy;                                      \
  if((f>0 && d>=0 && d<=f) || (f<0 && d<=0 && d>=f))  \
  {                                                   \
    e=Ax*Cy-Ay*Cx;                                    \
    if(f>0)                                           \
    {                                                 \
      if(e>=0 && e<=f) return 1;                      \
    }                                                 \
    else                                              \
    {                                                 \
      if(e<=0 && e>=f) return 1;                      \
    }                                                 \
  }

Definition at line 80 of file triangle_triangle3.h.

#define FABS (   x)    (T(fabs(x)))

Triangle/triangle intersection ,based on the algorithm presented in "A Fast Triangle-Triangle Intersection Test", Journal of Graphics Tools, 2(2), 1997

Definition at line 50 of file triangle_triangle3.h.

#define MULT (   dest,
  v,
  factor 
)    dest[0]=factor*v[0]; dest[1]=factor*v[1]; dest[2]=factor*v[2];

Definition at line 361 of file triangle_triangle3.h.

#define NEWCOMPUTE_INTERVALS (   VV0,
  VV1,
  VV2,
  D0,
  D1,
  D2,
  D0D1,
  D0D2,
  A,
  B,
  C,
  X0,
  X1 
)

Definition at line 201 of file triangle_triangle3.h.

#define POINT_IN_TRI (   V0,
  U0,
  U1,
  U2 
)
Value:
{                                           \
  T a,b,c,d0,d1,d2;                     \
  /* is T1 completly inside T2? */          \
  /* check if V0 is inside tri(U0,U1,U2) */ \
  a=U1[i1]-U0[i1];                          \
  b=-(U1[i0]-U0[i0]);                       \
  c=-a*U0[i0]-b*U0[i1];                     \
  d0=a*V0[i0]+b*V0[i1]+c;                   \
                                            \
  a=U2[i1]-U1[i1];                          \
  b=-(U2[i0]-U1[i0]);                       \
  c=-a*U1[i0]-b*U1[i1];                     \
  d1=a*V0[i0]+b*V0[i1]+c;                   \
                                            \
  a=U0[i1]-U2[i1];                          \
  b=-(U0[i0]-U2[i0]);                       \
  c=-a*U2[i0]-b*U2[i1];                     \
  d2=a*V0[i0]+b*V0[i1]+c;                   \
  if(d0*d1>0.0)                             \
  {                                         \
    if(d0*d2>0.0) return 1;                 \
  }                                         \
}

Definition at line 113 of file triangle_triangle3.h.

#define SET (   dest,
  src 
)    dest[0]=src[0]; dest[1]=src[1]; dest[2]=src[2];

Definition at line 362 of file triangle_triangle3.h.

#define SORT (   a,
 
)
Value:
if(a>b)    \
             {          \
               T c; \
               c=a;     \
               a=b;     \
               b=c;     \
             }

Definition at line 70 of file triangle_triangle3.h.

#define SORT2 (   a,
  b,
  smallest 
)
Value:
if(a>b)       \
             {             \
               float c;    \
               c=a;        \
               a=b;        \
               b=c;        \
               smallest=1; \
             }             \
             else smallest=0;

Definition at line 364 of file triangle_triangle3.h.

#define SUB (   dest,
  v1,
  v2 
)
Value:
{         \
            dest[0]=v1[0]-v2[0]; \
            dest[1]=v1[1]-v2[1]; \
            dest[2]=v1[2]-v2[2];}

Definition at line 64 of file triangle_triangle3.h.

#define TRI_TRI_INT_EPSILON   0.000001

Definition at line 53 of file triangle_triangle3.h.

Definition at line 52 of file triangle_triangle3.h.


Typedef Documentation

typedef Box2< double > vcg::Box2d

Specificazione di box of double.

Definition at line 388 of file box.h.

typedef Box2< float > vcg::Box2f

Specificazione di box of float.

Definition at line 387 of file box.h.

typedef Box2< int > vcg::Box2i

Specificazione di box of int.

Definition at line 386 of file box.h.

typedef Box2< short > vcg::Box2s

Specificazione di box of short.

Definition at line 385 of file box.h.

typedef Box3< double > vcg::Box3d

Definition at line 383 of file box.h.

typedef Box3< float > vcg::Box3f

Definition at line 382 of file box.h.

typedef Box3< int > vcg::Box3i

Definition at line 381 of file box.h.

typedef Box3< short > vcg::Box3s

Definition at line 380 of file box.h.

template<class ScalarTriangleType>
typedef Box3<ScalarType> vcg::Triangle3< ScalarTriangleType >::BoxType

The bounding box type.

Definition at line 48 of file triangle3.h.

typedef Color4<unsigned char> vcg::Color4b

Definition at line 365 of file color4.h.

typedef Color4<double> vcg::Color4d

Definition at line 367 of file color4.h.

typedef Color4<float> vcg::Color4f

Definition at line 366 of file color4.h.

template<class SCALAR_TYPE>
typedef Point2< ScalarType > vcg::Triangle2< SCALAR_TYPE >::CoordType

Definition at line 46 of file triangle2.h.

template<class ScalarTriangleType>
typedef Point3< ScalarType > vcg::Triangle3< ScalarTriangleType >::CoordType

Definition at line 46 of file triangle3.h.

typedef Line2<double> vcg::Line2d

Definition at line 179 of file line2.h.

typedef Line2<double,true> vcg::Line2dN

Definition at line 184 of file line2.h.

typedef Line2<float> vcg::Line2f

Definition at line 178 of file line2.h.

typedef Line2<float ,true> vcg::Line2fN

Definition at line 183 of file line2.h.

typedef Line2<int> vcg::Line2i

Definition at line 177 of file line2.h.

typedef Line2<int ,true> vcg::Line2iN

Definition at line 182 of file line2.h.

typedef Line2<short> vcg::Line2s

Definition at line 176 of file line2.h.

typedef Line2<short ,true> vcg::Line2sN

Definition at line 181 of file line2.h.

typedef Line3<double> vcg::Line3d

Definition at line 195 of file line3.h.

typedef Line3<double,true> vcg::Line3dN

Definition at line 200 of file line3.h.

typedef Line3<float> vcg::Line3f

Definition at line 194 of file line3.h.

typedef Line3<float ,true> vcg::Line3fN

Definition at line 199 of file line3.h.

typedef Line3<int> vcg::Line3i

Definition at line 193 of file line3.h.

typedef Line3<int ,true> vcg::Line3iN

Definition at line 198 of file line3.h.

typedef Line3<short> vcg::Line3s

Definition at line 192 of file line3.h.

typedef Line3<short ,true> vcg::Line3sN

Definition at line 197 of file line3.h.

typedef Plane3<double> vcg::Plane3d

Definition at line 148 of file plane3.h.

typedef Plane3<float> vcg::Plane3f

Definition at line 147 of file plane3.h.

typedef Point2<double> vcg::Point2d

Definition at line 365 of file deprecated_point2.h.

typedef Point2<double> vcg::ndim::Point2d

Definition at line 936 of file deprecated_point.h.

typedef Point2<float> vcg::Point2f

Definition at line 364 of file deprecated_point2.h.

typedef Point2<float> vcg::ndim::Point2f

Definition at line 935 of file deprecated_point.h.

typedef Point2<int> vcg::Point2i

Definition at line 363 of file deprecated_point2.h.

typedef Point2<int> vcg::ndim::Point2i

Definition at line 934 of file deprecated_point.h.

typedef Point2<short> vcg::Point2s

Definition at line 362 of file deprecated_point2.h.

typedef Point2<short> vcg::ndim::Point2s

Definition at line 933 of file deprecated_point.h.

typedef Point3<double> vcg::Point3d

Definition at line 605 of file deprecated_point3.h.

typedef Point3<double> vcg::ndim::Point3d

Definition at line 945 of file deprecated_point.h.

typedef Point3<float> vcg::Point3f

Definition at line 604 of file deprecated_point3.h.

typedef Point3<float> vcg::ndim::Point3f

Definition at line 944 of file deprecated_point.h.

typedef Point3<int> vcg::Point3i

Definition at line 603 of file deprecated_point3.h.

typedef Point3<int> vcg::ndim::Point3i

Definition at line 943 of file deprecated_point.h.

typedef Point3<short> vcg::Point3s

Definition at line 602 of file deprecated_point3.h.

typedef Point3<short> vcg::ndim::Point3s

Definition at line 942 of file deprecated_point.h.

typedef Point4<double> vcg::Point4d

Definition at line 391 of file deprecated_point4.h.

typedef Point4<double> vcg::ndim::Point4d

Definition at line 955 of file deprecated_point.h.

typedef Point4<float> vcg::Point4f

Definition at line 390 of file deprecated_point4.h.

typedef Point4<float> vcg::ndim::Point4f

Definition at line 954 of file deprecated_point.h.

typedef Point4<int> vcg::Point4i

Definition at line 389 of file deprecated_point4.h.

typedef Point4<int> vcg::ndim::Point4i

Definition at line 953 of file deprecated_point.h.

typedef Point4<short> vcg::Point4s

Definition at line 388 of file deprecated_point4.h.

typedef Point4<short> vcg::ndim::Point4s

Definition at line 952 of file deprecated_point.h.

template<class T, bool NORM = true>
typedef Point3<T> vcg::Plane3< T, NORM >::PointType

Definition at line 50 of file plane3.h.

template<class SegmentScalarType>
typedef Point2<SegmentScalarType> vcg::Segment2< SegmentScalarType >::PointType

The point type.

Definition at line 56 of file segment2.h.

template<class S>
typedef Point2<ScalarType> vcg::PointSegment2DEPFunctor< S >::QueryType

Definition at line 166 of file segment2.h.

typedef Ray2<double> vcg::Ray2d

Definition at line 180 of file ray2.h.

typedef Ray2<double,true> vcg::Ray2dN

Definition at line 185 of file ray2.h.

typedef Ray2<float> vcg::Ray2f

Definition at line 179 of file ray2.h.

typedef Ray2<float ,true> vcg::Ray2fN

Definition at line 184 of file ray2.h.

typedef Ray2<int> vcg::Ray2i

Definition at line 178 of file ray2.h.

typedef Ray2<int ,true> vcg::Ray2iN

Definition at line 183 of file ray2.h.

typedef Ray2<short> vcg::Ray2s

Definition at line 177 of file ray2.h.

typedef Ray2<short ,true> vcg::Ray2sN

Definition at line 182 of file ray2.h.

typedef Ray3<double> vcg::Ray3d

Definition at line 186 of file ray3.h.

typedef Ray3<double,true> vcg::Ray3dN

Definition at line 191 of file ray3.h.

typedef Ray3<float> vcg::Ray3f

Definition at line 185 of file ray3.h.

typedef Ray3<float ,true> vcg::Ray3fN

Definition at line 190 of file ray3.h.

typedef Ray3<int> vcg::Ray3i

Definition at line 184 of file ray3.h.

typedef Ray3<int ,true> vcg::Ray3iN

Definition at line 189 of file ray3.h.

typedef Ray3<short> vcg::Ray3s

Definition at line 183 of file ray3.h.

typedef Ray3<short ,true> vcg::Ray3sN

Definition at line 188 of file ray3.h.

template<class SCALAR_TYPE>
typedef SCALAR_TYPE vcg::Triangle2< SCALAR_TYPE >::ScalarType

Definition at line 45 of file triangle2.h.

template<class ScalarTriangleType>
typedef ScalarTriangleType vcg::Triangle3< ScalarTriangleType >::ScalarType

Definition at line 45 of file triangle3.h.

template<class T, bool NORM = true>
typedef T vcg::Plane3< T, NORM >::ScalarType

Definition at line 49 of file plane3.h.

template<class SegmentScalarType>
typedef SegmentScalarType vcg::Segment2< SegmentScalarType >::ScalarType

The scalar type.

Definition at line 53 of file segment2.h.

template<class T>
typedef T vcg::Sphere3< T >::ScalarType

Definition at line 80 of file sphere3.h.

template<class S>
typedef S vcg::PointSegment2DEPFunctor< S >::ScalarType

Definition at line 165 of file segment2.h.

typedef Segment2<double> vcg::Segment2d

Definition at line 144 of file segment2.h.

typedef Segment2<float> vcg::Segment2f

Definition at line 143 of file segment2.h.

typedef Segment2<int> vcg::Segment2i

Definition at line 142 of file segment2.h.

typedef Segment2<short> vcg::Segment2s

Definition at line 141 of file segment2.h.

typedef Segment3<double> vcg::Segment3d

Definition at line 165 of file segment3.h.

typedef Segment3<float> vcg::Segment3f

Definition at line 164 of file segment3.h.

typedef Segment3<int> vcg::Segment3i

Definition at line 163 of file segment3.h.

typedef Segment3<short> vcg::Segment3s

Definition at line 162 of file segment3.h.

template<class SegmentScalarType>
typedef Segment2<SegmentScalarType> vcg::Segment2< SegmentScalarType >::SegmentType

The point type.

Definition at line 59 of file segment2.h.

typedef Sphere3<double> vcg::Sphere3d

Definition at line 123 of file sphere3.h.

typedef Sphere3<float> vcg::Sphere3f

Definition at line 122 of file sphere3.h.

typedef TexCoord2<double> vcg::TexCoord2d

Definition at line 213 of file texcoord2.h.

typedef TexCoord2<float> vcg::TexCoord2f

Definition at line 212 of file texcoord2.h.

template<class SCALAR_TYPE>
typedef Triangle2<ScalarType> vcg::Triangle2< SCALAR_TYPE >::TriangleType

Definition at line 47 of file triangle2.h.

typedef Point2<double> vcg::ndim::Vector2d

Definition at line 940 of file deprecated_point.h.

typedef Point2<float> vcg::ndim::Vector2f

Definition at line 939 of file deprecated_point.h.

typedef Point2<int> vcg::ndim::Vector2i

Definition at line 938 of file deprecated_point.h.

typedef Point2<short> vcg::ndim::Vector2s

Definition at line 937 of file deprecated_point.h.

typedef Point3<double> vcg::ndim::Vector3d

Definition at line 949 of file deprecated_point.h.

typedef Point3<float> vcg::ndim::Vector3f

Definition at line 948 of file deprecated_point.h.

typedef Point3<int> vcg::ndim::Vector3i

Definition at line 947 of file deprecated_point.h.

typedef Point3<short> vcg::ndim::Vector3s

Definition at line 946 of file deprecated_point.h.

typedef Point4<double> vcg::ndim::Vector4d

Definition at line 959 of file deprecated_point.h.

typedef Point4<float> vcg::ndim::Vector4f

Definition at line 958 of file deprecated_point.h.

typedef Point4<int> vcg::ndim::Vector4i

Definition at line 957 of file deprecated_point.h.

typedef Point4<short> vcg::ndim::Vector4s

Definition at line 956 of file deprecated_point.h.


Enumeration Type Documentation

template<typename T >
enum vcg::ColorSpace::ConeResponse
Enumerator:
BRADFORD 
VON_KRIES 
XYZ_SCALING 

Definition at line 119 of file colorspace.h.

template<typename T >
enum vcg::ColorSpace::Illuminant
Enumerator:
VCG_ILLUMINANT_A 
VCG_ILLUMINANT_B 
VCG_ILLUMINANT_C 
VCG_ILLUMINANT_D50 
VCG_ILLUMINANT_D55 
VCG_ILLUMINANT_D65 
VCG_ILLUMINANT_D75 
VCG_ILLUMINANT_E 
VCG_ILLUMINANT_INVALID 

Definition at line 121 of file colorspace.h.

template<typename T >
enum vcg::ColorSpace::RGBSpaces
Enumerator:
ADOBE_RGB 
APPLE_RGB 
BEST_RGB 
BETA_RGB 
BRUCE_RGB 
CIE_RGB 
COLOR_MATCH 
DON_RGB4 
ECI_RGB 
EKTA_SPACE 
NTSC_RGB 
PAL_RGB 
PROPHOTO 
SMPTE_C 
SRGB 
WIDE_GAMUT 

Definition at line 134 of file colorspace.h.


Function Documentation

template<class SCALARTYPE >
Point2<SCALARTYPE> vcg::Abs ( const Point2< SCALARTYPE > &  p) [inline]

Definition at line 358 of file deprecated_point2.h.

template<class SCALARTYPE >
Point3<SCALARTYPE> vcg::Abs ( const Point3< SCALARTYPE > &  p) [inline]

Definition at line 593 of file deprecated_point3.h.

template<class T>
void vcg::Sphere3< T >::Add ( const Point3< T > &  p)

Definition at line 151 of file sphere3.h.

template<class T>
void vcg::Sphere3< T >::Add ( const Sphere3< T > &  sphere)

Definition at line 125 of file sphere3.h.

template<class T >
T vcg::Angle ( Point2< T > const &  p0,
Point2< T > const &  p1 
) [inline]

Definition at line 317 of file deprecated_point2.h.

template<class T >
T vcg::Angle ( const Point4< T > &  p1,
const Point4< T > &  p2 
)

Definition at line 348 of file deprecated_point4.h.

template<class P3ScalarType >
P3ScalarType vcg::Angle ( Point3< P3ScalarType > const &  p1,
Point3< P3ScalarType > const &  p2 
) [inline]

Definition at line 449 of file deprecated_point3.h.

template<class S >
S vcg::ndim::Angle ( Point3< S > const &  p1,
Point3< S > const &  p2 
) [inline]

Definition at line 856 of file deprecated_point.h.

template<class P3ScalarType >
P3ScalarType vcg::AngleN ( Point3< P3ScalarType > const &  p1,
Point3< P3ScalarType > const &  p2 
) [inline]

Definition at line 461 of file deprecated_point3.h.

template<class S >
S vcg::ndim::AngleN ( Point3< S > const &  p1,
Point3< S > const &  p2 
) [inline]

Definition at line 868 of file deprecated_point.h.

template<class P3ScalarType >
P3ScalarType vcg::ApproximateGeodesicDistance ( const Point3< P3ScalarType > &  p0,
const Point3< P3ScalarType > &  n0,
const Point3< P3ScalarType > &  p1,
const Point3< P3ScalarType > &  n1 
)

Definition at line 504 of file deprecated_point3.h.

template<class TriangleType >
Point3<typename TriangleType::ScalarType> vcg::Barycenter ( const TriangleType &  t)

Definition at line 256 of file triangle3.h.

template<class ScalarType >
Point3<ScalarType> vcg::Barycenter ( const Tetra3< ScalarType > &  t)

Definition at line 493 of file tetra3.h.

template<class SegmentScalarType>
Box2<ScalarType> vcg::Segment2< SegmentScalarType >::BBox ( ) const [inline]

return the bounding box

Definition at line 94 of file segment2.h.

template<typename T >
static double vcg::ColorSpace< T >::CA ( int  index) [inline, static, private]

Definition at line 353 of file colorspace.h.

template<class T>
Point3<T>& vcg::Sphere3< T >::Center ( ) [inline]

Definition at line 86 of file sphere3.h.

template<class T>
const Point3<T>& vcg::Sphere3< T >::Center ( ) const [inline]

Definition at line 87 of file sphere3.h.

template<typename T >
static Color4<T> vcg::ColorSpace< T >::chromaticAdaptation ( const Color4< T > &  color,
Illuminant  src,
Illuminant  dst,
ConeResponse  response = BRADFORD 
) [inline, static]

Definition at line 1927 of file colorspace.h.

template<typename T >
static void vcg::ColorSpace< T >::chromaticAdaptation ( double  Xi,
double  Yi,
double  Zi,
Illuminant  src,
double &  X,
double &  Y,
double &  Z,
Illuminant  dst,
ConeResponse  response = BRADFORD 
) [inline, static]

Definition at line 1939 of file colorspace.h.

template<typename T >
static double vcg::ColorSpace< T >::CIE_EPSILON ( ) [inline, static, private]

Definition at line 157 of file colorspace.h.

template<typename T >
static double vcg::ColorSpace< T >::CIE_KI ( ) [inline, static, private]

Definition at line 162 of file colorspace.h.

template<typename T >
static Color4<T> vcg::ColorSpace< T >::CIELabtoXYZ ( const Color4< T > &  color,
Illuminant  ref 
) [inline, static]

Definition at line 1719 of file colorspace.h.

template<typename T >
static void vcg::ColorSpace< T >::CIELabtoXYZ ( double  L,
double  a,
double  b,
double &  X,
double &  Y,
double &  Z,
Illuminant  whiteRef 
) [inline, static]

Definition at line 1728 of file colorspace.h.

template<class ScalarType >
bool vcg::CircleLineIntersection ( const vcg::Line2< ScalarType > &  line,
const vcg::Point2< ScalarType > &  center,
const ScalarType radius,
vcg::Point2< ScalarType > &  p0,
vcg::Point2< ScalarType > &  p1 
) [inline]

translate with origin on the center

no intersection

Definition at line 326 of file intersection2.h.

template<class TriangleType >
Point3<typename TriangleType::ScalarType> vcg::Circumcenter ( const TriangleType &  t)

Definition at line 270 of file triangle3.h.

Color4<float> vcg::Clamp ( Color4< float > &  c) [inline]

Definition at line 344 of file color4.h.

template<class ScalarType >
Point2<ScalarType> vcg::ClosestPoint ( Segment2< ScalarType s,
const Point2< ScalarType > &  p 
)

Definition at line 147 of file segment2.h.

template<class ScalarType , bool NORM>
Point2<ScalarType> vcg::ClosestPoint ( Line2< ScalarType, NORM >  l,
const Point2< ScalarType > &  p 
)

returns closest point

Definition at line 188 of file line2.h.

template<class ScalarType , bool NORM>
Point2<ScalarType> vcg::ClosestPoint ( Ray2< ScalarType, NORM >  r,
const Point2< ScalarType > &  p 
)

returns closest point

Definition at line 189 of file ray2.h.

template<class ScalarType , bool NORM>
Point3<ScalarType> vcg::ClosestPoint ( Ray3< ScalarType, NORM >  r,
const Point3< ScalarType > &  p 
)

returns closest point

Definition at line 195 of file ray3.h.

template<class ScalarType , bool NORM>
Point3<ScalarType> vcg::ClosestPoint ( Line3< ScalarType, NORM >  l,
const Point3< ScalarType > &  p 
)

returns closest point

Definition at line 204 of file line3.h.

template<class ScalarType >
Point2<ScalarType> vcg::ClosestPoint2Box2 ( const Point2< ScalarType > &  test,
const Box2< ScalarType > &  bbox 
)

Definition at line 330 of file box2.h.

template<class T >
int vcg::compute_intervals_isectline ( Point3< T VERT0,
Point3< T VERT1,
Point3< T VERT2,
float  VV0,
float  VV1,
float  VV2,
float  D0,
float  D1,
float  D2,
float  D0D1,
float  D0D2,
float *  isect0,
float *  isect1,
Point3< T > &  isectpoint0,
Point3< T > &  isectpoint1 
) [inline]

Definition at line 393 of file triangle_triangle3.h.

template<class TetraType >
TetraType::ScalarType vcg::ComputeVolume ( const TetraType &  t)

Definition at line 500 of file tetra3.h.

template<class SegmentScalarType>
template<class Q >
static SegmentType vcg::Segment2< SegmentScalarType >::Construct ( const Segment2< Q > &  b) [inline, static]

copy constructor (builds a new segment importing an existing one)

Definition at line 122 of file segment2.h.

template<class SCALAR_TYPE >
bool vcg::Convex ( const Point2< SCALAR_TYPE > &  p0,
const Point2< SCALAR_TYPE > &  p1,
const Point2< SCALAR_TYPE > &  p2 
) [inline]

return true if the algle is convex (right rotation)

Function computing the intersection between couple of geometric primitives in 2 dimension

Definition at line 57 of file intersection2.h.

template<class T >
bool vcg::coplanar_tri_tri ( const Point3< T N,
const Point3< T V0,
const Point3< T V1,
const Point3< T V2,
const Point3< T U0,
const Point3< T U1,
const Point3< T U2 
)

CHeck two triangles for coplanarity

Parameters:
N
V0A vertex of the first triangle
V1A vertex of the first triangle
V2A vertex of the first triangle
U0A vertex of the second triangle
U1A vertex of the second triangle
U2A vertex of the second triangle
Returns:
true se due triangoli sono cooplanari, false altrimenti

Definition at line 150 of file triangle_triangle3.h.

template<class TriangleType >
TriangleType::ScalarType vcg::CosWedge ( const TriangleType &  t,
int  k 
)

Definition at line 247 of file triangle3.h.

template<class ScalarTriangleType>
const CoordType& vcg::Triangle3< ScalarTriangleType >::cP ( const int  j) const [inline]

Definition at line 67 of file triangle3.h.

template<class ScalarTriangleType>
const CoordType& vcg::Triangle3< ScalarTriangleType >::cP0 ( const int  j) const [inline]

Definition at line 71 of file triangle3.h.

template<class SCALAR_TYPE>
const CoordType& vcg::Triangle2< SCALAR_TYPE >::cP0 ( const int  j) const [inline]

Definition at line 73 of file triangle2.h.

template<class ScalarTriangleType>
const CoordType& vcg::Triangle3< ScalarTriangleType >::cP1 ( const int  j) const [inline]

Definition at line 72 of file triangle3.h.

template<class SCALAR_TYPE>
const CoordType& vcg::Triangle2< SCALAR_TYPE >::cP1 ( const int  j) const [inline]

Definition at line 74 of file triangle2.h.

template<class ScalarTriangleType>
const CoordType& vcg::Triangle3< ScalarTriangleType >::cP2 ( const int  j) const [inline]

Definition at line 73 of file triangle3.h.

template<class SCALAR_TYPE>
const CoordType& vcg::Triangle2< SCALAR_TYPE >::cP2 ( const int  j) const [inline]

Definition at line 75 of file triangle2.h.

template<class T>
int vcg::Sphere3< T >::CreateFromBox ( int  n,
const Point3< T > *  points 
)

Definition at line 187 of file sphere3.h.

template<class T>
int vcg::Sphere3< T >::CreateTight ( int  n,
const Point3< T > *  points,
T  threshold = 1.01,
T  speed = 0.6 
)

Definition at line 200 of file sphere3.h.

template<class T>
int vcg::Sphere3< T >::CreateTight ( const std::vector< Point3< T > > &  points,
T  threshold = 1.01,
T  speed = 0.6 
)

Definition at line 257 of file sphere3.h.

template<class ScalarType >
bool vcg::Cross ( const Point2< ScalarType > &  p00,
const Point2< ScalarType > &  p01,
const Point2< ScalarType > &  p10,
const Point2< ScalarType > &  p11 
)

A very simple earcut tessellation of planar 2D polygon. Input: a vector or Point2<> Output: a vector of faces as a triple of indices to the input vector

Definition at line 41 of file planar_polygon_tessellation.h.

template<class T, bool NORM = true>
const PointType& vcg::Plane3< T, NORM >::Direction ( ) const [inline]

Definition at line 85 of file plane3.h.

template<class ScalarType , bool NORM>
ScalarType vcg::Distance ( const Line2< ScalarType, NORM > &  l,
const Point2< ScalarType > &  p 
)

Definition at line 194 of file line2.h.

template<class ScalarType , bool NORM>
ScalarType vcg::Distance ( const Line3< ScalarType, NORM > &  l,
const Point3< ScalarType > &  p 
)

Definition at line 210 of file line3.h.

template<class T >
T vcg::Distance ( Point2< T > const &  p1,
Point2< T > const &  p2 
) [inline]

Definition at line 348 of file deprecated_point2.h.

template<class T >
T vcg::Distance ( const Point4< T > &  p1,
const Point4< T > &  p2 
) [inline]

Definition at line 370 of file deprecated_point4.h.

template<class P3ScalarType >
P3ScalarType vcg::Distance ( Point3< P3ScalarType > const &  p1,
Point3< P3ScalarType > const &  p2 
) [inline]

Definition at line 492 of file deprecated_point3.h.

template<int N, class S >
S vcg::ndim::Distance ( Point< N, S > const &  p1,
Point< N, S > const &  p2 
) [inline]

Definition at line 899 of file deprecated_point.h.

template<class ScalarType >
ScalarType vcg::DistancePoint2Box2 ( const Point2< ScalarType > &  test,
const Box2< ScalarType > &  bbox 
)

test possible position respect to bounding box

Definition at line 281 of file box2.h.

template<class TriangleType >
TriangleType::ScalarType vcg::DoubleArea ( const TriangleType &  t)

Return the Double of area of the triangle.

Definition at line 241 of file triangle3.h.

template<class SegmentScalarType>
void vcg::Segment2< SegmentScalarType >::Flip ( ) [inline]

flips: a-b becomes b-a

Definition at line 113 of file segment2.h.

template<typename T >
static double vcg::ColorSpace< T >::gamma ( RGBSpaces  rgb_space) [inline, static]

Definition at line 1313 of file colorspace.h.

template<class T>
Box3< T > vcg::Point3< T >::GetBBox ( Box3< T > &  bb) const

Definition at line 328 of file box3.h.

template<class P3ScalarType >
void vcg::GetUV ( Point3< P3ScalarType > &  n,
Point3< P3ScalarType > &  u,
Point3< P3ScalarType > &  v,
Point3< P3ScalarType >  up = (Point3<P3ScalarType>(0,1,0)) 
)

Definition at line 569 of file deprecated_point3.h.

template<typename T >
static Color4<T> vcg::ColorSpace< T >::HSLtoRGB ( const Color4< T > &  color) [inline, static]

Definition at line 1834 of file colorspace.h.

template<typename T >
static void vcg::ColorSpace< T >::HSLtoRGB ( double  H,
double  S,
double  L,
double &  R,
double &  G,
double &  B 
) [inline, static]

Definition at line 1844 of file colorspace.h.

template<typename T >
static Color4<T> vcg::ColorSpace< T >::HSVtoRGB ( const Color4< T > &  color) [inline, static]

Definition at line 1500 of file colorspace.h.

template<typename T >
static void vcg::ColorSpace< T >::HSVtoRGB ( double  H,
double  S,
double  V,
double &  R,
double &  G,
double &  B 
) [inline, static]

Definition at line 1509 of file colorspace.h.

template<typename T >
static double vcg::ColorSpace< T >::Hue2RGB ( double  v1,
double  v2,
double  vH 
) [inline, static]

Definition at line 1870 of file colorspace.h.

template<class T, bool NORM = true>
template<class Q >
void vcg::Plane3< T, NORM >::Import ( const Plane3< Q, false > &  b) [inline]

Definition at line 68 of file plane3.h.

template<class SegmentScalarType>
template<class Q >
void vcg::Segment2< SegmentScalarType >::Import ( const Segment2< Q > &  b) [inline]

importer for different line types

Definition at line 117 of file segment2.h.

template<class T, bool NORM = true>
void vcg::Plane3< T, NORM >::Init ( const PointType p0,
const PointType p1,
const PointType p2 
) [inline]

Calculates the plane passing through three points (Rename this method)

Definition at line 133 of file plane3.h.

template<class T, bool NORM = true>
void vcg::Plane3< T, NORM >::Init ( const PointType p0,
const PointType norm 
) [inline]

Calculates the plane passing through a point and the normal (Rename this method.

Definition at line 140 of file plane3.h.

template<class SCALAR_TYPE>
bool vcg::Triangle2< SCALAR_TYPE >::InterpolationParameters ( const CoordType bq,
ScalarType L1,
ScalarType L2,
ScalarType L3 
) const [inline]

evaluate barycentric coordinates

Parameters:
bqPoint on the face
L0barycentric value for V(0)
L1barycentric value for V(1)
L2barycentric value for V(2)
Returns:
true se bq appartain to the face, false otherwise from http://en.wikipedia.org/wiki/Barycentric_coordinate_system_(mathematics) L1=((y2-y3)(x-x3)+(x3-x2)(y-y3))/((y2-y3)(x1-x3)+(x3-x2)(y1-y3)) L2=((y3-y1)(x-x3)+(x1-x3)(y-y3))/((y3-y1)(x2-x3)+(x1-x3)(y2-y3)) L3=1-L1-L2

Definition at line 88 of file triangle2.h.

template<class TriangleType , class ScalarType >
bool vcg::InterpolationParameters ( const TriangleType  t,
const int  Axis,
const Point3< ScalarType > &  P,
Point3< ScalarType > &  L 
)

Definition at line 113 of file triangle3.h.

template<class TriangleType , class ScalarType >
bool vcg::InterpolationParameters ( const TriangleType  t,
const Point3< ScalarType > &  N,
const Point3< ScalarType > &  P,
Point3< ScalarType > &  L 
)

Handy Wrapper of the above one that uses the passed normal N to choose the right orientation.

Definition at line 123 of file triangle3.h.

template<class TriangleType , class ScalarType >
bool vcg::InterpolationParameters ( const TriangleType  t,
const Point3< ScalarType > &  P,
Point3< ScalarType > &  L 
)

Handy Wrapper of the above one that calculate the normal on the triangle.

Definition at line 154 of file triangle3.h.

template<class ScalarType >
bool vcg::InterpolationParameters2 ( const Point2< ScalarType > &  V1,
const Point2< ScalarType > &  V2,
const Point2< ScalarType > &  V3,
const Point2< ScalarType > &  P,
Point3< ScalarType > &  L 
)

Definition at line 143 of file triangle3.h.

template<class S >
bool vcg::Intersect ( size_t  cur,
int  v2,
std::vector< int > &  next,
std::vector< Point2< S > > &  points2 
)

Definition at line 54 of file planar_polygon_tessellation.h.

template<class T >
void vcg::Sphere3< T >::Intersect ( const Sphere3< T > &  sphere)

Definition at line 176 of file sphere3.h.

template<class T >
bool vcg::IntersectionLineBox ( const Box3< T > &  box,
const Line3< T > &  r,
Point3< T > &  coord 
)

Definition at line 432 of file intersection3.h.

template<class T >
bool vcg::IntersectionLinePlane ( const Line3< T > &  li,
const Plane3< T > &  pl,
Point3< T > &  po 
) [inline]

intersection between line and plane

Definition at line 233 of file intersection3.h.

template<class T >
bool vcg::IntersectionLineSphere ( const Sphere3< T > &  sp,
const Line3< T > &  li,
Point3< T > &  p0,
Point3< T > &  p1 
) [inline]

interseciton between sphere and line

Function computing the intersection between couple of geometric primitives in 3 dimension

Definition at line 49 of file intersection3.h.

template<class T >
bool vcg::IntersectionLineTriangle ( const Line3< T > &  line,
const Point3< T > &  vert0,
const Point3< T > &  vert1,
const Point3< T > &  vert2,
T t,
T u,
T v 
)

Definition at line 359 of file intersection3.h.

template<class ScalarType >
bool vcg::IntersectionPlaneBox ( const vcg::Plane3< ScalarType > &  pl,
vcg::Box3< ScalarType > &  bbox 
)

Definition at line 615 of file intersection3.h.

template<class T >
bool vcg::IntersectionPlaneLine ( const Plane3< T > &  pl,
const Line3< T > &  li,
Point3< T > &  po 
) [inline]

intersection between line and plane

Definition at line 221 of file intersection3.h.

template<class T >
bool vcg::IntersectionPlanePlane ( const Plane3< T > &  plane0,
const Plane3< T > &  plane1,
Line3< T > &  line 
)

Definition at line 678 of file intersection3.h.

template<class T >
bool vcg::IntersectionPlaneSegment ( const Plane3< T > &  pl,
const Segment3< T > &  s,
Point3< T > &  p0 
) [inline]

intersection between segment and plane

Definition at line 240 of file intersection3.h.

template<class ScalarType >
bool vcg::IntersectionPlaneSegmentEpsilon ( const Plane3< ScalarType > &  pl,
const Segment3< ScalarType > &  sg,
Point3< ScalarType > &  po,
const ScalarType  epsilon = ScalarType(1e-8) 
) [inline]

intersection between segment and plane

Definition at line 258 of file intersection3.h.

template<typename TRIANGLETYPE >
bool vcg::IntersectionPlaneTriangle ( const Plane3< typename TRIANGLETYPE::ScalarType > &  pl,
const TRIANGLETYPE &  tr,
Segment3< typename TRIANGLETYPE::ScalarType > &  sg 
) [inline]

intersection between plane and triangle

Definition at line 279 of file intersection3.h.

template<class T >
bool vcg::IntersectionRayBox ( const Box3< T > &  box,
const Ray3< T > &  r,
Point3< T > &  coord 
)

Definition at line 506 of file intersection3.h.

template<class T >
bool vcg::IntersectionRayTriangle ( const Ray3< T > &  ray,
const Point3< T > &  vert0,
const Point3< T > &  vert1,
const Point3< T > &  vert2,
T t,
T u,
T v 
)

Definition at line 418 of file intersection3.h.

template<class ScalarType >
bool vcg::IntersectionSegmentBox ( const Box3< ScalarType > &  box,
const Segment3< ScalarType > &  s,
Point3< ScalarType > &  coord 
)

Definition at line 516 of file intersection3.h.

template<class ScalarType >
int vcg::IntersectionSegmentBox ( const Box3< ScalarType > &  box,
const Segment3< ScalarType > &  s,
Point3< ScalarType > &  coord0,
Point3< ScalarType > &  coord1 
)

Definition at line 541 of file intersection3.h.

template<class SCALAR_TYPE >
int vcg::IntersectionSegmentSphere ( const Sphere3< SCALAR_TYPE > &  sphere,
const Segment3< SCALAR_TYPE > &  segment,
Point3< SCALAR_TYPE > &  t0,
Point3< SCALAR_TYPE > &  t1 
) [inline]

Definition at line 86 of file intersection3.h.

template<class ScalarType >
bool vcg::IntersectionSegmentTriangle ( const vcg::Segment3< ScalarType > &  seg,
const Point3< ScalarType > &  vert0,
const Point3< ScalarType > &  vert1,
const Point3< ScalarType > &  vert2,
ScalarType a,
ScalarType b 
)

Compute the intersection between a segment and a triangle. It relies on the lineTriangle Intersection

Parameters:
[in]segment
[in]trianglevertices
[out](t,u,v)the intersection point, meaningful only if the line of segment intersects the triangle t is the baricentric coord of the point on the segment (u,v) are the baricentric coords of the intersection point in the segment

Definition at line 571 of file intersection3.h.

template<class TriangleType >
bool vcg::IntersectionSegmentTriangle ( const vcg::Segment3< typename TriangleType::ScalarType > &  seg,
const TriangleType &  t,
typename TriangleType::ScalarType a,
typename TriangleType::ScalarType b 
)

Compute the intersection between a segment and a triangle. Wrapper of the above function

Definition at line 607 of file intersection3.h.

template<class SphereType >
bool vcg::IntersectionSphereSphere ( const SphereType &  s0,
const SphereType &  s1 
)

Definition at line 673 of file intersection3.h.

template<class SCALAR_TYPE , class TRIANGLETYPE >
bool vcg::IntersectionSphereTriangle ( const vcg::Sphere3< SCALAR_TYPE > &  sphere,
TRIANGLETYPE  triangle,
vcg::Point3< SCALAR_TYPE > &  witness,
std::pair< SCALAR_TYPE, SCALAR_TYPE > *  res = NULL 
)

Compute the intersection between a sphere and a triangle.

Parameters:
[in]spherethe input sphere
[in]trianglethe input triangle
[out]witnessit is the point on the triangle nearest to the center of the sphere (even when there isn't intersection)
[out]resif not null, in the first item is stored the minimum distance between the triangle and the sphere, while in the second item is stored the penetration depth
Returns:
true iff there is an intersection between the sphere and the triangle

Definition at line 137 of file intersection3.h.

template<class ScalarType >
bool vcg::IntersectionTriangleBox ( const vcg::Box3< ScalarType > &  bbox,
const vcg::Point3< ScalarType > &  p0,
const vcg::Point3< ScalarType > &  p1,
const vcg::Point3< ScalarType > &  p2 
)

control bounding box collision

control if each point is inside the bouding box

then control intersection of segments with box

control intersection of diagonal of the cube with triangle

Definition at line 626 of file intersection3.h.

template<typename TRIANGLETYPE >
bool vcg::IntersectionTriangleTriangle ( const TRIANGLETYPE &  t0,
const TRIANGLETYPE &  t1 
) [inline]

intersection between two triangles

Definition at line 310 of file intersection3.h.

template<class T >
bool vcg::IntersectionTriangleTriangle ( Point3< T V0,
Point3< T V1,
Point3< T V2,
Point3< T U0,
Point3< T U1,
Point3< T U2 
) [inline]

Definition at line 316 of file intersection3.h.

template<class SCALAR_TYPE>
bool vcg::Triangle2< SCALAR_TYPE >::IsCCW ( ) [inline]

retutn true if the face is contuerclockwise oriented

Definition at line 136 of file triangle2.h.

template<class T >
void vcg::isect2 ( Point3< T VTX0,
Point3< T VTX1,
Point3< T VTX2,
float  VV0,
float  VV1,
float  VV2,
float  D0,
float  D1,
float  D2,
float *  isect0,
float *  isect1,
Point3< T > &  isectpoint0,
Point3< T > &  isectpoint1 
) [inline]

Definition at line 376 of file triangle_triangle3.h.

template<class T>
bool vcg::Sphere3< T >::IsEmpty ( ) const [inline]

Definition at line 89 of file sphere3.h.

template<class T>
bool vcg::Sphere3< T >::IsIn ( const Point3< T > &  p) const

return true if

Parameters:
p- Center() <= Radius()

Definition at line 163 of file sphere3.h.

template<class T>
bool vcg::Sphere3< T >::IsIn ( const Sphere3< T > &  p) const

Definition at line 169 of file sphere3.h.

template<class SCALAR_TYPE >
bool vcg::IsInsideTrianglePoint ( const Triangle2< SCALAR_TYPE > &  t,
const Point2< SCALAR_TYPE > &  p 
) [inline]

interseciton between point and triangle

first test with bounding box

then text convex

Definition at line 225 of file intersection2.h.

template<class SegmentScalarType>
ScalarType vcg::Segment2< SegmentScalarType >::Length ( ) [inline]

returns segment length

Definition at line 102 of file segment2.h.

template<class SegmentScalarType>
ScalarType vcg::Segment2< SegmentScalarType >::Length ( ) const [inline]

returns segment length

Definition at line 106 of file segment2.h.

template<class SegmentScalarType>
PointType vcg::Segment2< SegmentScalarType >::Lerp ( const ScalarType  t) const [inline]

calculates the point of parameter t on the segment. if t is in [0..1] returned point is inside the segment

Definition at line 88 of file segment2.h.

template<class SCALAR_TYPE >
bool vcg::LineLineIntersection ( const vcg::Line2< SCALAR_TYPE > &  l0,
const vcg::Line2< SCALAR_TYPE > &  l1,
Point2< SCALAR_TYPE > &  p 
) [inline]

return if exist the intersection point between 2 lines in a 2d plane

first line

second line

then find intersection

denominator

Definition at line 66 of file intersection2.h.

template<class SCALAR_TYPE >
bool vcg::LineSegmentIntersection ( const vcg::Line2< SCALAR_TYPE > &  line,
const vcg::Segment2< SCALAR_TYPE > &  seg,
Point2< SCALAR_TYPE > &  p_inters 
) [inline]

interseciton between point and triangle

first compute intersection between lines

then test if intersection point is nearest to both extremes then length of the segment

Definition at line 170 of file intersection2.h.

template<class SCALARTYPE >
Point3<SCALARTYPE> vcg::LowClampToZero ( const Point3< SCALARTYPE > &  p) [inline]

Definition at line 598 of file deprecated_point3.h.

template<class SegmentScalarType>
PointType vcg::Segment2< SegmentScalarType >::MidPoint ( ) const [inline]

return the middle point

Definition at line 91 of file segment2.h.

template<class T, bool NORM = true>
PointType vcg::Plane3< T, NORM >::Mirror ( const PointType p) const [inline]

Mirror the point wrt the plane.

Definition at line 121 of file plane3.h.

template<class ScalarType , bool NORM>
vcg::Point2<ScalarType> vcg::Mirror ( const vcg::Line2< ScalarType, NORM > &  l,
const vcg::Point2< ScalarType > &  p 
)

Definition at line 201 of file line2.h.

template<class T >
bool vcg::NoDivTriTriIsect ( const Point3< T V0,
const Point3< T V1,
const Point3< T V2,
const Point3< T U0,
const Point3< T U1,
const Point3< T U2 
)

Definition at line 245 of file triangle_triangle3.h.

template<class T >
T vcg::Norm ( Point2< T > const &  p) [inline]

Definition at line 333 of file deprecated_point2.h.

template<class T >
T vcg::Norm ( const Point4< T > &  p) [inline]

Definition at line 358 of file deprecated_point4.h.

template<class P3ScalarType >
P3ScalarType vcg::Norm ( Point3< P3ScalarType > const &  p) [inline]

Definition at line 473 of file deprecated_point3.h.

template<int N, class S >
S vcg::ndim::Norm ( Point< N, S > const &  p) [inline]

Definition at line 880 of file deprecated_point.h.

template<class Point3Type >
Point3Type vcg::Normal ( Point3Type const &  p0,
Point3Type const &  p1,
Point3Type const &  p2 
)

Definition at line 93 of file triangle3.h.

template<class TetraType >
Point3<typename TetraType::ScalarType> vcg::Normal ( const TetraType &  t,
const int &  face 
)

Returns the normal to the face face of the tetrahedron t.

Definition at line 506 of file tetra3.h.

template<class T, bool NORM = true>
void vcg::Plane3< T, NORM >::Normalize ( void  ) [inline]

Function to normalize direction.

Definition at line 128 of file plane3.h.

template<class T >
Point2<T>& vcg::Normalize ( Point2< T > &  p) [inline]

Definition at line 343 of file deprecated_point2.h.

template<class P3ScalarType >
Point3<P3ScalarType>& vcg::Normalize ( Point3< P3ScalarType > &  p) [inline]

Definition at line 485 of file deprecated_point3.h.

template<int N, class S >
Point<N,S>& vcg::ndim::Normalize ( Point< N, S > &  p) [inline]

Definition at line 892 of file deprecated_point.h.

template<class TriangleType >
TriangleType::CoordType vcg::NormalizedTriangleNormal ( const TriangleType &  t)

Returns the normal to the plane passing through p0,p1,p2.

Definition at line 88 of file triangle3.h.

template<class T, bool NORM = true>
const ScalarType& vcg::Plane3< T, NORM >::Offset ( ) const [inline]

Definition at line 80 of file plane3.h.

template<class T, bool NORM = true>
ScalarType& vcg::Plane3< T, NORM >::Offset ( ) [inline]

Definition at line 81 of file plane3.h.

template<class SegmentScalarType>
bool vcg::Segment2< SegmentScalarType >::operator!= ( SegmentType const &  p) const [inline]

Operator to dispare segments.

Definition at line 81 of file segment2.h.

template<class T, bool NORM = true>
bool vcg::Plane3< T, NORM >::operator!= ( Plane3< T, NORM > const &  p) const [inline]

Operator to dispare two lines.

Definition at line 110 of file plane3.h.

template<class S>
template<class EdgeType , class ScalarType >
bool vcg::PointSegment2DEPFunctor< S >::operator() ( const EdgeType &  e,
const Point2< ScalarType > &  p,
ScalarType minDist,
Point2< ScalarType > &  q 
) [inline]

Definition at line 170 of file segment2.h.

template<class SegmentScalarType>
SegmentType vcg::Segment2< SegmentScalarType >::operator* ( const ScalarType  s) const [inline]

Definition at line 131 of file segment2.h.

template<class T >
Point2<T> vcg::operator* ( const T  s,
Point2< T > const &  p 
) [inline]

Definition at line 328 of file deprecated_point2.h.

template<class SegmentScalarType>
SegmentType vcg::Segment2< SegmentScalarType >::operator+ ( SegmentType const &  p) const [inline]

Definition at line 127 of file segment2.h.

template<class SegmentScalarType>
SegmentType vcg::Segment2< SegmentScalarType >::operator- ( SegmentType const &  p) const [inline]

Definition at line 129 of file segment2.h.

template<class T >
Point2<T> vcg::operator- ( Point2< T > const &  p) [inline]

Definition at line 323 of file deprecated_point2.h.

template<class SegmentScalarType>
SegmentType vcg::Segment2< SegmentScalarType >::operator/ ( const ScalarType  s) const [inline]

Definition at line 133 of file segment2.h.

template<class SegmentScalarType>
bool vcg::Segment2< SegmentScalarType >::operator== ( SegmentType const &  p) const [inline]

Operator to compare segments.

Definition at line 78 of file segment2.h.

template<class T, bool NORM = true>
bool vcg::Plane3< T, NORM >::operator== ( Plane3< T, NORM > const &  p) const [inline]

Operator to compare two lines.

Definition at line 106 of file plane3.h.

template<class ScalarTriangleType>
CoordType& vcg::Triangle3< ScalarTriangleType >::P ( const int  j) [inline]

Shortcut per accedere ai punti delle facce.

Definition at line 62 of file triangle3.h.

template<class SCALAR_TYPE>
CoordType& vcg::Triangle2< SCALAR_TYPE >::P ( const int  j) [inline]

Shortcut per accedere ai punti delle facce.

Definition at line 65 of file triangle2.h.

template<class ScalarTriangleType>
const CoordType& vcg::Triangle3< ScalarTriangleType >::P ( const int  j) const [inline]

Definition at line 66 of file triangle3.h.

template<class SCALAR_TYPE>
const CoordType& vcg::Triangle2< SCALAR_TYPE >::P ( const int  j) const [inline]

Definition at line 69 of file triangle2.h.

template<class ScalarTriangleType>
CoordType& vcg::Triangle3< ScalarTriangleType >::P0 ( const int  j) [inline]

Definition at line 63 of file triangle3.h.

template<class SCALAR_TYPE>
CoordType& vcg::Triangle2< SCALAR_TYPE >::P0 ( const int  j) [inline]

Definition at line 66 of file triangle2.h.

template<class ScalarTriangleType>
const CoordType& vcg::Triangle3< ScalarTriangleType >::P0 ( const int  j) const [inline]

Definition at line 68 of file triangle3.h.

template<class SegmentScalarType>
const PointType& vcg::Segment2< SegmentScalarType >::P0 ( ) const [inline]

Members to access either extrema.

Definition at line 69 of file segment2.h.

template<class SCALAR_TYPE>
const CoordType& vcg::Triangle2< SCALAR_TYPE >::P0 ( const int  j) const [inline]

Definition at line 70 of file triangle2.h.

template<class SegmentScalarType>
PointType& vcg::Segment2< SegmentScalarType >::P0 ( ) [inline]

Definition at line 71 of file segment2.h.

template<class ScalarTriangleType>
CoordType& vcg::Triangle3< ScalarTriangleType >::P1 ( const int  j) [inline]

Definition at line 64 of file triangle3.h.

template<class SCALAR_TYPE>
CoordType& vcg::Triangle2< SCALAR_TYPE >::P1 ( const int  j) [inline]

Definition at line 67 of file triangle2.h.

template<class ScalarTriangleType>
const CoordType& vcg::Triangle3< ScalarTriangleType >::P1 ( const int  j) const [inline]

Definition at line 69 of file triangle3.h.

template<class SegmentScalarType>
const PointType& vcg::Segment2< SegmentScalarType >::P1 ( ) const [inline]

Definition at line 70 of file segment2.h.

template<class SCALAR_TYPE>
const CoordType& vcg::Triangle2< SCALAR_TYPE >::P1 ( const int  j) const [inline]

Definition at line 71 of file triangle2.h.

template<class SegmentScalarType>
PointType& vcg::Segment2< SegmentScalarType >::P1 ( ) [inline]

Definition at line 72 of file segment2.h.

template<class ScalarTriangleType>
CoordType& vcg::Triangle3< ScalarTriangleType >::P2 ( const int  j) [inline]

Definition at line 65 of file triangle3.h.

template<class SCALAR_TYPE>
CoordType& vcg::Triangle2< SCALAR_TYPE >::P2 ( const int  j) [inline]

Definition at line 68 of file triangle2.h.

template<class ScalarTriangleType>
const CoordType& vcg::Triangle3< ScalarTriangleType >::P2 ( const int  j) const [inline]

Definition at line 70 of file triangle3.h.

template<class SCALAR_TYPE>
const CoordType& vcg::Triangle2< SCALAR_TYPE >::P2 ( const int  j) const [inline]

Definition at line 72 of file triangle2.h.

template<class TriangleType >
TriangleType::ScalarType vcg::Perimeter ( const TriangleType &  t)

Definition at line 262 of file triangle3.h.

template<class T, bool NORM = true>
vcg::Plane3< T, NORM >::Plane3 ( ) [inline]

The empty constructor.

Definition at line 63 of file plane3.h.

template<class T, bool NORM = true>
vcg::Plane3< T, NORM >::Plane3 ( const ScalarType dist,
const PointType dir 
) [inline]

The (distance, direction) constructor.

Definition at line 65 of file plane3.h.

template<class SCALAR_TYPE>
void vcg::Triangle2< SCALAR_TYPE >::PointDistance ( const CoordType q,
ScalarType dist,
CoordType p 
) const [inline]

return the distance to the point q and neighors point p

find distance to each segment and take minimum

Definition at line 116 of file triangle2.h.

template<class ScalarType >
bool vcg::PointInsidePolygon ( vcg::Point2< ScalarType p,
const std::vector< vcg::Segment2< ScalarType > > &  polygon 
)

take 4 directions

Definition at line 285 of file intersection2.h.

template<class S>
static const Point2<ScalarType>& vcg::PointSegment2DEPFunctor< S >::Pos ( const QueryType qt) [inline, static]

Definition at line 167 of file segment2.h.

template<class T, bool NORM = true>
PointType vcg::Plane3< T, NORM >::Projection ( const PointType p) const [inline]

Project a point on the plane.

Definition at line 115 of file plane3.h.

template<class P3ScalarType >
P3ScalarType vcg::PSDist ( const Point3< P3ScalarType > &  p,
const Point3< P3ScalarType > &  v1,
const Point3< P3ScalarType > &  v2,
Point3< P3ScalarType > &  q 
)

Point(p) Edge(v1-v2) dist, q is the point in v1-v2 with min dist.

Definition at line 554 of file deprecated_point3.h.

template<class P3ScalarType >
P3ScalarType vcg::Quality ( Point3< P3ScalarType > const &  p0,
Point3< P3ScalarType > const &  p1,
Point3< P3ScalarType > const &  p2 
)

Compute a shape quality measure of the triangle composed by points p0,p1,p2 It Returns 2*AreaTri/(MaxEdge^2), the range is range [0.0, 0.866] e.g. Equilateral triangle sqrt(3)/2, halfsquare: 1/2, ... up to a line that has zero quality.

Definition at line 168 of file triangle3.h.

template<class TriangleType >
TriangleType::ScalarType vcg::QualityFace ( const TriangleType &  t)

Return the _q of the face, the return value is in [0,sqrt(3)/2] = [0 - 0.866.. ].

Definition at line 188 of file triangle3.h.

template<class P3ScalarType >
P3ScalarType vcg::QualityMeanRatio ( Point3< P3ScalarType > const &  p0,
Point3< P3ScalarType > const &  p1,
Point3< P3ScalarType > const &  p2 
)

Compute a shape quality measure of the triangle composed by points p0,p1,p2 It Returns mean ratio 2sqrt(a, b)/(a+b) where a+b are the eigenvalues of the M^tM of the transformation matrix into a regular simplex the range is range [0, 1]

Definition at line 218 of file triangle3.h.

template<class P3ScalarType >
P3ScalarType vcg::QualityRadii ( Point3< P3ScalarType > const &  p0,
Point3< P3ScalarType > const &  p1,
Point3< P3ScalarType > const &  p2 
)

Compute a shape quality measure of the triangle composed by points p0,p1,p2 It Returns inradius/circumradius the range is range [0, 1] e.g. Equilateral triangle 1, halfsquare: 0.81, ... up to a line that has zero quality.

Definition at line 197 of file triangle3.h.

template<class T>
T& vcg::Sphere3< T >::Radius ( ) [inline]

Definition at line 84 of file sphere3.h.

template<class T>
const T& vcg::Sphere3< T >::Radius ( ) const [inline]

Definition at line 85 of file sphere3.h.

template<class SCALAR_TYPE >
bool vcg::RayBoxIntersection ( const vcg::Ray2< SCALAR_TYPE > &  r,
const vcg::Box2< SCALAR_TYPE > &  bbox,
Point2< SCALAR_TYPE > &  p_inters 
) [inline]

interseciton between point and triangle

first create the 4 segments

Definition at line 142 of file intersection2.h.

template<class SCALAR_TYPE >
bool vcg::RayLineIntersection ( const vcg::Line2< SCALAR_TYPE > &  l,
const vcg::Ray2< SCALAR_TYPE > &  r,
Point2< SCALAR_TYPE > &  p 
) [inline]

return if exist the intersection point between 2 lines in a 2d plane

construct line from ray

Definition at line 103 of file intersection2.h.

template<class SCALAR_TYPE >
bool vcg::RaySegmentIntersection ( const vcg::Ray2< SCALAR_TYPE > &  r,
const vcg::Segment2< SCALAR_TYPE > &  seg,
Point2< SCALAR_TYPE > &  p_inters 
) [inline]

interseciton between point and triangle

first compute intersection between lines

then test if intersection point is nearest to both extremes then length of the segment

Definition at line 120 of file intersection2.h.

template<typename T >
static Illuminant vcg::ColorSpace< T >::refIlluminant ( RGBSpaces  rgb_space) [inline, static]

Definition at line 1382 of file colorspace.h.

template<typename T >
static double vcg::ColorSpace< T >::RGB2XYZ ( int  index) [inline, static, private]

Definition at line 167 of file colorspace.h.

template<typename T >
static Color4<T> vcg::ColorSpace< T >::RGBtoHSL ( const Color4< T > &  color) [inline, static]

Definition at line 1781 of file colorspace.h.

template<typename T >
static void vcg::ColorSpace< T >::RGBtoHSL ( double  R,
double  G,
double  B,
double &  H,
double &  S,
double &  L 
) [inline, static]

Definition at line 1791 of file colorspace.h.

template<typename T >
static Color4<T> vcg::ColorSpace< T >::RGBtoHSV ( const Color4< T > &  color) [inline, static]

Definition at line 1456 of file colorspace.h.

template<typename T >
static void vcg::ColorSpace< T >::RGBtoHSV ( double  R,
double  G,
double  B,
double &  H,
double &  S,
double &  V 
) [inline, static]

Definition at line 1465 of file colorspace.h.

template<typename T >
static Color4<T> vcg::ColorSpace< T >::RGBtoRGB ( const Color4< T > &  color,
RGBSpaces  rgbsrc,
RGBSpaces  rgbdest,
ConeResponse  response = BRADFORD 
) [inline, static]

Definition at line 1951 of file colorspace.h.

template<typename T >
static void vcg::ColorSpace< T >::RGBtoRGB ( double  Ri,
double  Gi,
double  Bi,
RGBSpaces  rgbsrc,
double &  R,
double &  G,
double &  B,
RGBSpaces  rgbdest,
ConeResponse  response = BRADFORD 
) [inline, static]

Definition at line 1963 of file colorspace.h.

template<typename T >
static Color4<T> vcg::ColorSpace< T >::RGBtoXYZ ( const Color4< T > &  color,
RGBSpaces  space,
Illuminant  dest,
ConeResponse  response = BRADFORD 
) [inline, static]

Definition at line 1623 of file colorspace.h.

template<typename T >
static void vcg::ColorSpace< T >::RGBtoXYZ ( double  R,
double  G,
double  B,
RGBSpaces  space,
double &  X,
double &  Y,
double &  Z,
Illuminant  dest,
ConeResponse  response = BRADFORD 
) [inline, static]

Definition at line 1633 of file colorspace.h.

template<class SegmentScalarType>
vcg::Segment2< SegmentScalarType >::Segment2 ( ) [inline]

The empty constructor.

Definition at line 74 of file segment2.h.

template<class SegmentScalarType>
vcg::Segment2< SegmentScalarType >::Segment2 ( const PointType a,
const PointType b 
) [inline]

The (a,b) constructor.

Definition at line 76 of file segment2.h.

template<class SCALAR_TYPE >
bool vcg::SegmentSegmentIntersection ( const vcg::Segment2< SCALAR_TYPE > &  seg0,
const vcg::Segment2< SCALAR_TYPE > &  seg1,
Point2< SCALAR_TYPE > &  p_inters 
) [inline]

interseciton between two segments

Definition at line 192 of file intersection2.h.

template<class SegmentScalarType>
void vcg::Segment2< SegmentScalarType >::Set ( const PointType a,
const PointType b 
) [inline]

initializes the segment with its extrema

Definition at line 84 of file segment2.h.

template<class T, bool NORM = true>
void vcg::Plane3< T, NORM >::Set ( const ScalarType off,
const PointType dir 
) [inline]

sets origin and direction.

Definition at line 92 of file plane3.h.

template<class T, bool NORM = true>
void vcg::Plane3< T, NORM >::Set ( const PointType dir,
const ScalarType off 
) [inline]

Definition at line 103 of file plane3.h.

template<class T, bool NORM = true>
void vcg::Plane3< T, NORM >::SetDirection ( const PointType dir) [inline]

sets the direction

Definition at line 87 of file plane3.h.

template<class T, bool NORM = true>
void vcg::Plane3< T, NORM >::SetOffset ( const ScalarType o) [inline]

sets the origin

Definition at line 83 of file plane3.h.

template<class T >
T vcg::SignedDistancePlanePoint ( const Plane3< T, true > &  plane,
const Point3< T > &  point 
)

Distance plane - point and vv. (Move these function to somewhere else)

Definition at line 151 of file plane3.h.

template<class T >
T vcg::SignedDistancePointPlane ( const Point3< T > &  point,
const Plane3< T, true > &  plane 
)

Definition at line 157 of file plane3.h.

template<class T>
vcg::Sphere3< T >::Sphere3 ( ) [inline]

Definition at line 81 of file sphere3.h.

template<class T>
vcg::Sphere3< T >::Sphere3 ( const Point3< T > &  center,
T  radius 
) [inline]

Definition at line 82 of file sphere3.h.

template<class T >
T vcg::SquaredDistance ( Point2< T > const &  p1,
Point2< T > const &  p2 
) [inline]

Definition at line 353 of file deprecated_point2.h.

template<class T >
T vcg::SquaredDistance ( const Point4< T > &  p1,
const Point4< T > &  p2 
) [inline]

Definition at line 376 of file deprecated_point4.h.

template<class P3ScalarType >
P3ScalarType vcg::SquaredDistance ( Point3< P3ScalarType > const &  p1,
Point3< P3ScalarType > const &  p2 
) [inline]

Definition at line 498 of file deprecated_point3.h.

template<int N, class S >
S vcg::ndim::SquaredDistance ( Point< N, S > const &  p1,
Point< N, S > const &  p2 
) [inline]

Definition at line 905 of file deprecated_point.h.

template<class SegmentScalarType>
ScalarType vcg::Segment2< SegmentScalarType >::SquaredLength ( ) [inline]

return segment squared length

Definition at line 110 of file segment2.h.

template<class T >
T vcg::SquaredNorm ( Point2< T > const &  p) [inline]

Definition at line 338 of file deprecated_point2.h.

template<class T >
T vcg::SquaredNorm ( const Point4< T > &  p) [inline]

Definition at line 364 of file deprecated_point4.h.

template<class P3ScalarType >
P3ScalarType vcg::SquaredNorm ( Point3< P3ScalarType > const &  p) [inline]

Definition at line 479 of file deprecated_point3.h.

template<int N, class S >
S vcg::ndim::SquaredNorm ( Point< N, S > const &  p) [inline]

Definition at line 886 of file deprecated_point.h.

template<class P3ScalarType >
double vcg::stable_dot ( Point3< P3ScalarType > const &  p0,
Point3< P3ScalarType > const &  p1 
)

Definition at line 522 of file deprecated_point3.h.

template<class T >
double vcg::StableDot ( Point4< T > const &  p0,
Point4< T > const &  p1 
)

slower version of dot product, more stable (double precision only)

Definition at line 383 of file deprecated_point4.h.

template<class POINT_CONTAINER >
void vcg::TessellatePlanarPolygon2 ( POINT_CONTAINER &  points2,
std::vector< int > &  output 
)

Definition at line 64 of file planar_polygon_tessellation.h.

template<class POINT_CONTAINER >
void vcg::TessellatePlanarPolygon3 ( POINT_CONTAINER &  points,
std::vector< int > &  output 
)

A very simple earcut tessellation of planar 2D polygon. Input: a vector or Point3<> Output: a vector of faces as a triple of indices to the input vector

Definition at line 113 of file planar_polygon_tessellation.h.

template<class T >
bool vcg::tri_tri_intersect_with_isectline ( Point3< T V0,
Point3< T V1,
Point3< T V2,
Point3< T U0,
Point3< T U1,
Point3< T U2,
bool &  coplanar,
Point3< T > &  isectpt1,
Point3< T > &  isectpt2 
)

Definition at line 465 of file triangle_triangle3.h.

template<class SCALAR_TYPE>
vcg::Triangle2< SCALAR_TYPE >::Triangle2 ( ) [inline]

Definition at line 54 of file triangle2.h.

template<class SCALAR_TYPE>
vcg::Triangle2< SCALAR_TYPE >::Triangle2 ( const CoordType p0,
const CoordType p1,
const CoordType p2 
) [inline]

Definition at line 57 of file triangle2.h.

template<class ScalarTriangleType>
vcg::Triangle3< ScalarTriangleType >::Triangle3 ( ) [inline]

Definition at line 54 of file triangle3.h.

template<class ScalarTriangleType>
vcg::Triangle3< ScalarTriangleType >::Triangle3 ( const CoordType c0,
const CoordType c1,
const CoordType c2 
) [inline]

Definition at line 55 of file triangle3.h.

template<class TriangleType >
TriangleType::CoordType vcg::TriangleNormal ( const TriangleType &  t)

Returns the normal to the plane passing through p0,p1,p2.

Definition at line 82 of file triangle3.h.

template<class ScalarType >
bool vcg::TriangleTriangleIntersect2D ( const vcg::Triangle2< ScalarType > &  tr0,
const vcg::Triangle2< ScalarType > &  tr1 
)

test BBox Intersection

test vertex in face

test segment to segment intersection

Definition at line 247 of file intersection2.h.

template<class ScalarTriangleType>
int vcg::Triangle3< ScalarTriangleType >::VN ( ) const [inline]

Definition at line 75 of file triangle3.h.

template<typename T >
static Color4<T> vcg::ColorSpace< T >::xyYtoXYZ ( const Color4< T > &  color) [inline, static]

Definition at line 1890 of file colorspace.h.

template<typename T >
static void vcg::ColorSpace< T >::xyYtoXYZ ( double  x,
double  y,
double  _Y,
double &  X,
double &  Y,
double &  Z 
) [inline, static]

Definition at line 1901 of file colorspace.h.

template<typename T >
static double vcg::ColorSpace< T >::XYZ2RGB ( int  index) [inline, static, private]

Definition at line 260 of file colorspace.h.

template<typename T >
static Color4<T> vcg::ColorSpace< T >::XYZtoCIELab ( const Color4< T > &  color,
Illuminant  ref 
) [inline, static]

Definition at line 1672 of file colorspace.h.

template<typename T >
static void vcg::ColorSpace< T >::XYZtoCIELab ( double  X,
double  Y,
double  Z,
double &  L,
double &  a,
double &  b,
Illuminant  whiteRef 
) [inline, static]

Definition at line 1681 of file colorspace.h.

template<typename T >
static Color4<T> vcg::ColorSpace< T >::XYZtoRGB ( const Color4< T > &  color,
Illuminant  src,
RGBSpaces  dest,
ConeResponse  response = BRADFORD 
) [inline, static]

Definition at line 1575 of file colorspace.h.

template<typename T >
static void vcg::ColorSpace< T >::XYZtoRGB ( double  X,
double  Y,
double  Z,
Illuminant  src,
double &  R,
double &  G,
double &  B,
RGBSpaces  space,
ConeResponse  response = BRADFORD 
) [inline, static]

Definition at line 1585 of file colorspace.h.

template<typename T >
static Color4<T> vcg::ColorSpace< T >::XYZtoxyY ( const Color4< T > &  color) [inline, static]

Definition at line 1908 of file colorspace.h.

template<typename T >
static void vcg::ColorSpace< T >::XYZtoxyY ( double  X,
double  _Y,
double  Z,
double &  x,
double &  y,
double &  Y 
) [inline, static]

Definition at line 1919 of file colorspace.h.


Variable Documentation

template<class T>
Point3<T> vcg::Sphere3< T >::_center [protected]

Definition at line 77 of file sphere3.h.

template<class T, bool NORM = true>
PointType vcg::Plane3< T, NORM >::_dir [private]

Direction (not necessarily normalized unless NORM is true)

Definition at line 56 of file plane3.h.

template<class T, bool NORM = true>
ScalarType vcg::Plane3< T, NORM >::_offset [private]

Distance.

Definition at line 54 of file plane3.h.

template<class SegmentScalarType>
PointType vcg::Segment2< SegmentScalarType >::_p0 [private]

_extrema

Definition at line 64 of file segment2.h.

template<class SegmentScalarType>
PointType vcg::Segment2< SegmentScalarType >::_p1 [private]

Definition at line 64 of file segment2.h.

template<class T>
T vcg::Sphere3< T >::_radius [protected]

Definition at line 78 of file sphere3.h.

template<class SCALAR_TYPE>
Point2<ScalarType> vcg::Triangle2< SCALAR_TYPE >::_v[3] [protected]

Vector of vertex pointer incident in the face.

Definition at line 51 of file triangle2.h.

template<class ScalarTriangleType>
Point3<ScalarType> vcg::Triangle3< ScalarTriangleType >::_v[3] [protected]

Vector of vertex pointer incident in the face.

Definition at line 58 of file triangle3.h.



shape_reconstruction
Author(s): Roberto Martín-Martín
autogenerated on Sat Jun 8 2019 18:39:00