Minor fix
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62
diff --git a/src/FTContour.cpp b/src/FTContour.cpp
index 724e8ba..b9e30c0 100644
--- a/src/FTContour.cpp
+++ b/src/FTContour.cpp
@@ -142,7 +142,7 @@ void FTContour::deCasteljau( const float t, const int n)
}
//Specify next vertex to be included on curve
- AddPoint( FTPoint( bValues[n][0][0], bValues[n][0][1], 0));
+ AddPoint( FTPoint( bValues[n][0][0], bValues[n][0][1], 0.0f));
}
diff --git a/src/FTVectoriser.cpp b/src/FTVectoriser.cpp
index 6683b14..00b161a 100644
--- a/src/FTVectoriser.cpp
+++ b/src/FTVectoriser.cpp
@@ -173,16 +173,15 @@ int FTVectoriser::points()
void FTVectoriser::GetOutline( FTGL_DOUBLE* data)
{
int i = 0;
-
for( size_t c= 0; c < contours(); ++c)
{
const FTContour* contour = contourList[c];
for( size_t p = 0; p < contour->size(); ++p)
{
- data[i] = static_cast<FTGL_DOUBLE>(contour->pointList[p].x / 64.0f); // is 64 correct?
+ data[i] = static_cast<FTGL_DOUBLE>(contour->pointList[p].x / 64.0f);
data[i + 1] = static_cast<FTGL_DOUBLE>(contour->pointList[p].y / 64.0f);
- data[i + 2] = 0.0f; // static_cast<FTGL_DOUBLE>(contour->pointList[p].z / 64.0f);
+ data[i + 2] = 0.0f;
i += 3;
}
}
@@ -243,12 +242,11 @@ void FTVectoriser::MakeMesh( FTGL_DOUBLE zNormal)
void FTVectoriser::GetMesh( FTGL_DOUBLE* data)
{
- int i = 0;
-
// fill out the header
size_t msize = mesh->tesselationList.size();
data[0] = msize;
+ int i = 0;
for( int p = 0; p < data[0]; ++p)
{
FTTesselation* tesselation = mesh->tesselationList[p];
@@ -261,9 +259,9 @@ void FTVectoriser::GetMesh( FTGL_DOUBLE* data)
i += 3;
for( size_t q = 0; q < ( tesselation->pointList.size()); ++q)
{
- data[i] = tesselation->pointList[q].x / 64.0f; // is 64 correct?
+ data[i] = tesselation->pointList[q].x / 64.0f;
data[i + 1] = tesselation->pointList[q].y / 64.0f;
- data[i + 2] = 0.0f; // static_cast<FTGL_DOUBLE>(mesh->pointList[p].z / 64.0f);
+ data[i + 2] = 0.0f;
i += 3;
}
}