Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2012-11-10 14:26:39 +0400
committerCampbell Barton <ideasman42@gmail.com>2012-11-10 14:26:39 +0400
commit250109f5ace8471451a6d8bda8f67ffc955eb4b7 (patch)
tree6228de4b3b9dd229e2b129549e69e6edf06c84be /source/gameengine/Rasterizer/RAS_TexVert.cpp
parentfecc3b9d68102630fc53f451a3f405f180b31384 (diff)
add argument so recent bge function mesh.transform_uv() so you can optionally transform between UV1 / UV2
Diffstat (limited to 'source/gameengine/Rasterizer/RAS_TexVert.cpp')
-rw-r--r--source/gameengine/Rasterizer/RAS_TexVert.cpp19
1 files changed, 15 insertions, 4 deletions
diff --git a/source/gameengine/Rasterizer/RAS_TexVert.cpp b/source/gameengine/Rasterizer/RAS_TexVert.cpp
index 6d8cbfece15..945644ff3e6 100644
--- a/source/gameengine/Rasterizer/RAS_TexVert.cpp
+++ b/source/gameengine/Rasterizer/RAS_TexVert.cpp
@@ -75,21 +75,32 @@ void RAS_TexVert::SetXYZ(const MT_Point3& xyz)
xyz.getValue(m_localxyz);
}
-void RAS_TexVert::SetXYZ(const float *xyz)
+void RAS_TexVert::SetXYZ(const float xyz[3])
{
m_localxyz[0] = xyz[0]; m_localxyz[1] = xyz[1]; m_localxyz[2] = xyz[2];
}
-void RAS_TexVert::SetUV(const MT_Point2& uv)
+void RAS_TexVert::SetUV1(const MT_Point2& uv)
{
uv.getValue(m_uv1);
}
+void RAS_TexVert::SetUV1(const float uv[3])
+{
+ m_uv1[0] = uv[0];
+ m_uv1[1] = uv[1];
+}
+
void RAS_TexVert::SetUV2(const MT_Point2& uv)
{
uv.getValue(m_uv2);
}
+void RAS_TexVert::SetUV2(const float uv[3])
+{
+ m_uv2[0] = uv[0];
+ m_uv2[1] = uv[1];
+}
void RAS_TexVert::SetRGBA(const unsigned int rgba)
{
@@ -151,9 +162,9 @@ void RAS_TexVert::Transform(const MT_Matrix4x4& mat, const MT_Matrix4x4& nmat)
SetTangent((nmat*MT_Vector4(m_tangent[0], m_tangent[1], m_tangent[2], 1.0)).getValue());
}
-void RAS_TexVert::TransformUV(const MT_Matrix4x4& mat)
+void RAS_TexVert::TransformUV1(const MT_Matrix4x4& mat)
{
- SetUV((mat * MT_Vector4(m_uv1[0], m_uv1[1], 0.0, 1.0)).getValue());
+ SetUV1((mat * MT_Vector4(m_uv1[0], m_uv1[1], 0.0, 1.0)).getValue());
}
void RAS_TexVert::TransformUV2(const MT_Matrix4x4& mat)