templated SimpleVoxelWithNormal class to ScalarType
This commit is contained in:
parent
0371a3c5be
commit
bb5288bcc0
|
|
@ -124,16 +124,18 @@ public:
|
||||||
vcg::Point3<ScalarType> &N() { static Point3<ScalarType> _p(0,0,0); return _p;}
|
vcg::Point3<ScalarType> &N() { static Point3<ScalarType> _p(0,0,0); return _p;}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
template <class _ScalarType=float>
|
||||||
class SimpleVoxelWithNormal
|
class SimpleVoxelWithNormal
|
||||||
{
|
{
|
||||||
private:
|
private:
|
||||||
float _v;
|
_ScalarType _v;
|
||||||
vcg::Point3f _n;
|
vcg::Point3<_ScalarType> _n;
|
||||||
public:
|
public:
|
||||||
float &V() {return _v;}
|
typedef _ScalarType ScalarType;
|
||||||
float V() const {return _v;}
|
ScalarType &V() {return _v;}
|
||||||
vcg::Point3f &N() {return _n;}
|
ScalarType V() const {return _v;}
|
||||||
vcg::Point3f N() const {return _n;}
|
vcg::Point3<ScalarType> &N() {return _n;}
|
||||||
|
vcg::Point3<ScalarType> N() const {return _n;}
|
||||||
static bool HasNormal() {return true;}
|
static bool HasNormal() {return true;}
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue