Improved float/double consistency removing some wrong Point3f and substitued with MeshType::CoordType

This commit is contained in:
Paolo Cignoni 2014-06-19 10:23:58 +00:00
parent 4198a3bd7c
commit c30978903d
1 changed files with 18 additions and 17 deletions

View File

@ -60,6 +60,7 @@ public:
typedef typename MeshType::FacePointer FacePointer;
typedef typename MeshType::FaceIterator FaceIterator;
typedef typename MeshType::ScalarType ScalarType;
typedef typename MeshType::CoordType CoordType;
class ColorAvgInfo
{
@ -329,10 +330,10 @@ Note: The faux bit is used to color polygonal faces uniformly
Period is expressed in absolute terms.
So as period it is meaningful could be to use something in the range of 1/10 of the bbox diag.
*/
static void PerVertexPerlinNoise(MeshType& m, Point3f period, Point3f offset=Point3f(0,0,0))
static void PerVertexPerlinNoise(MeshType& m, CoordType period, CoordType offset=CoordType(0,0,0))
{
if(!HasPerVertexColor(m)) throw MissingComponentException("PerVertexColor");
Point3<ScalarType> p[3];
CoordType p[3];
for(VertexIterator vi = m.vert.begin(); vi!=m.vert.end(); ++vi)
{
if(!(*vi).IsD()){