diff options
author | Campbell Barton <ideasman42@gmail.com> | 2013-05-02 02:41:55 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2013-05-02 02:41:55 +0400 |
commit | dee33e80970ff0b83a06b2dd5d23b8e25f7317df (patch) | |
tree | 437f98d8bc3e1d4a37cf33b2bef6090a06526fc0 /source/gameengine/Ketsji | |
parent | 3bbf11761a78e45be465f7ebb3a7e4dfc1f9b13b (diff) |
fix [#34609] mesh.getVertex doesn't work as spected with poly.getMaterialIndex() and poly vertex indexes
revert r22906 (own old commit, was incorrectly trying to make vertex indices absolute)
Diffstat (limited to 'source/gameengine/Ketsji')
-rw-r--r-- | source/gameengine/Ketsji/KX_PolyProxy.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/source/gameengine/Ketsji/KX_PolyProxy.cpp b/source/gameengine/Ketsji/KX_PolyProxy.cpp index eaedc752201..83092c7d89c 100644 --- a/source/gameengine/Ketsji/KX_PolyProxy.cpp +++ b/source/gameengine/Ketsji/KX_PolyProxy.cpp @@ -140,21 +140,21 @@ PyObject *KX_PolyProxy::pyattr_get_v1(void *self_v, const KX_PYATTRIBUTE_DEF *at { KX_PolyProxy* self = static_cast<KX_PolyProxy*>(self_v); - return PyLong_FromLong(self->m_polygon->GetVertexOffsetAbs(self->m_mesh, 0)); + return PyLong_FromLong(self->m_polygon->GetVertexOffset(0)); } PyObject *KX_PolyProxy::pyattr_get_v2(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef) { KX_PolyProxy* self = static_cast<KX_PolyProxy*>(self_v); - return PyLong_FromLong(self->m_polygon->GetVertexOffsetAbs(self->m_mesh, 1)); + return PyLong_FromLong(self->m_polygon->GetVertexOffset(1)); } PyObject *KX_PolyProxy::pyattr_get_v3(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef) { KX_PolyProxy* self = static_cast<KX_PolyProxy*>(self_v); - return PyLong_FromLong(self->m_polygon->GetVertexOffsetAbs(self->m_mesh, 2)); + return PyLong_FromLong(self->m_polygon->GetVertexOffset(2)); } PyObject *KX_PolyProxy::pyattr_get_v4(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef) @@ -163,7 +163,7 @@ PyObject *KX_PolyProxy::pyattr_get_v4(void *self_v, const KX_PYATTRIBUTE_DEF *at if (3 < self->m_polygon->VertexCount()) { - return PyLong_FromLong(self->m_polygon->GetVertexOffsetAbs(self->m_mesh, 3)); + return PyLong_FromLong(self->m_polygon->GetVertexOffset(3)); } return PyLong_FromLong(0); } @@ -243,7 +243,7 @@ KX_PYMETHODDEF_DOC(KX_PolyProxy, getVertexIndex, } if (index < m_polygon->VertexCount()) { - return PyLong_FromLong(m_polygon->GetVertexOffsetAbs(m_mesh, index)); + return PyLong_FromLong(m_polygon->GetVertexOffset(index)); } return PyLong_FromLong(0); } |