diff options
author | hwc487 | 2012-06-29 15:13:14 -0700 |
---|---|---|
committer | hwc487 | 2012-06-29 15:13:14 -0700 |
commit | ab80aa9c7da912db384ec48c656f84fd673b5253 (patch) | |
tree | 78e9cea2df2a77b431bfbb3ae460125f54081d2e /js/lib/geom/circle.js | |
parent | 44eba9c1f7935ae13e87a6dcf6ddea0efa63eb05 (diff) | |
download | ninja-ab80aa9c7da912db384ec48c656f84fd673b5253.tar.gz |
'V' texture map coordinate was inverted in some cases.
Diffstat (limited to 'js/lib/geom/circle.js')
-rwxr-xr-x | js/lib/geom/circle.js | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/js/lib/geom/circle.js b/js/lib/geom/circle.js index 374dda58..11c6dd33 100755 --- a/js/lib/geom/circle.js +++ b/js/lib/geom/circle.js | |||
@@ -401,16 +401,6 @@ exports.Circle = Object.create(GeomObj, { | |||
401 | 401 | ||
402 | this.recalcTexMapCoords( vrts, uvs ); | 402 | this.recalcTexMapCoords( vrts, uvs ); |
403 | 403 | ||
404 | // //refine the mesh for vertex deformations | ||
405 | // if (material) { | ||
406 | // if (material.hasVertexDeformation()) { | ||
407 | // var paramRange = material.getVertexDeformationRange(); | ||
408 | // var tolerance = material.getVertexDeformationTolerance(); | ||
409 | // ShapePrimitive.refineMesh( vrts, nrms, uvs, indices, vrts.length/3, paramRange, tolerance ); | ||
410 | // } | ||
411 | // } | ||
412 | |||
413 | // return ShapePrimitive.create(vrts, nrms, uvs, indices, RDGE.globals.engine.getContext().renderer.TRIANGLES, index); | ||
414 | // refine the mesh for vertex deformations | 404 | // refine the mesh for vertex deformations |
415 | var rtnArray; | 405 | var rtnArray; |
416 | if (material) | 406 | if (material) |
@@ -919,7 +909,7 @@ exports.Circle = Object.create(GeomObj, { | |||
919 | if (uvs[iuv] > uMax) uMax = uvs[iuv]; | 909 | if (uvs[iuv] > uMax) uMax = uvs[iuv]; |
920 | 910 | ||
921 | iuv++; ivrt++; | 911 | iuv++; ivrt++; |
922 | uvs[iuv] = (vrts[ivrt]-yMin)/ovalHeight; | 912 | uvs[iuv] = 1.0 - (vrts[ivrt]-yMin)/ovalHeight; |
923 | if (uvs[iuv] < vMin) vMin = uvs[iuv]; | 913 | if (uvs[iuv] < vMin) vMin = uvs[iuv]; |
924 | if (uvs[iuv] > vMax) vMax = uvs[iuv]; | 914 | if (uvs[iuv] > vMax) vMax = uvs[iuv]; |
925 | iuv++; ivrt += 2; | 915 | iuv++; ivrt += 2; |