|
|
|
@ -556,14 +556,16 @@ public class TangentBinormalGenerator { |
|
|
|
|
|
|
|
|
|
public static TriangleData processTriangle(int[] index, |
|
|
|
|
Vector3f[] v, Vector2f[] t) { |
|
|
|
|
Vector3f edge1 = new Vector3f(); |
|
|
|
|
Vector3f edge2 = new Vector3f(); |
|
|
|
|
Vector2f edge1uv = new Vector2f(); |
|
|
|
|
Vector2f edge2uv = new Vector2f(); |
|
|
|
|
TempVars tmp = TempVars.get(); |
|
|
|
|
try { |
|
|
|
|
Vector3f edge1 = tmp.vect1; |
|
|
|
|
Vector3f edge2 = tmp.vect2; |
|
|
|
|
Vector2f edge1uv = tmp.vect2d; |
|
|
|
|
Vector2f edge2uv = tmp.vect2d2; |
|
|
|
|
|
|
|
|
|
Vector3f tangent = new Vector3f(); |
|
|
|
|
Vector3f binormal = new Vector3f(); |
|
|
|
|
Vector3f normal = new Vector3f(); |
|
|
|
|
Vector3f tangent = tmp.vect3; |
|
|
|
|
Vector3f binormal = tmp.vect4; |
|
|
|
|
Vector3f normal = tmp.vect5; |
|
|
|
|
|
|
|
|
|
t[1].subtract(t[0], edge1uv); |
|
|
|
|
t[2].subtract(t[0], edge2uv); |
|
|
|
@ -617,6 +619,9 @@ public class TangentBinormalGenerator { |
|
|
|
|
tangent, |
|
|
|
|
binormal, |
|
|
|
|
normal); |
|
|
|
|
} finally { |
|
|
|
|
tmp.release(); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
public static void setToleranceAngle(float angle) { |
|
|
|
|