diff options
Diffstat (limited to 'source/blender/blenkernel/intern/DerivedMesh.c')
-rw-r--r-- | source/blender/blenkernel/intern/DerivedMesh.c | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/source/blender/blenkernel/intern/DerivedMesh.c b/source/blender/blenkernel/intern/DerivedMesh.c index 0c99735f73e..aaed0381b2e 100644 --- a/source/blender/blenkernel/intern/DerivedMesh.c +++ b/source/blender/blenkernel/intern/DerivedMesh.c @@ -292,7 +292,7 @@ void DM_to_meshkey(DerivedMesh *dm, Mesh *me, KeyBlock *kb) mvert=dm->getVertDataArray(dm, CD_MVERT); for(a=0; a<kb->totelem; a++, fp+=3, mvert++) { - VECCOPY(fp, mvert->co); + copy_v3_v3(fp, mvert->co); } } @@ -604,12 +604,12 @@ static void emDM_drawUVEdges(DerivedMesh *dm) static void emDM__calcFaceCent(EditFace *efa, float cent[3], float (*vertexCos)[3]) { if (vertexCos) { - VECCOPY(cent, vertexCos[(int) efa->v1->tmp.l]); + copy_v3_v3(cent, vertexCos[(int) efa->v1->tmp.l]); add_v3_v3(cent, vertexCos[(int) efa->v2->tmp.l]); add_v3_v3(cent, vertexCos[(int) efa->v3->tmp.l]); if (efa->v4) add_v3_v3(cent, vertexCos[(int) efa->v4->tmp.l]); } else { - VECCOPY(cent, efa->v1->co); + copy_v3_v3(cent, efa->v1->co); add_v3_v3(cent, efa->v2->co); add_v3_v3(cent, efa->v3->co); if (efa->v4) add_v3_v3(cent, efa->v4->co); @@ -1184,7 +1184,7 @@ static void emDM_getVert(DerivedMesh *dm, int index, MVert *vert_r) for(i = 0; i < index; ++i) ev = ev->next; - VECCOPY(vert_r->co, ev->co); + copy_v3_v3(vert_r->co, ev->co); normal_float_to_short_v3(vert_r->no, ev->no); @@ -1539,8 +1539,9 @@ static float *get_editmesh_orco_verts(EditMesh *em) orco = MEM_mallocN(sizeof(float)*3*totvert, "EditMesh Orco"); - for(a=0, eve=em->verts.first; eve; eve=eve->next, a+=3) - VECCOPY(orco+a, eve->co); + for(a=0, eve=em->verts.first; eve; eve=eve->next, a+=3) { + copy_v3_v3(orco+a, eve->co); + } return orco; } @@ -2146,7 +2147,7 @@ float (*editmesh_get_vertex_cos(EditMesh *em, int *numVerts_r))[3] cos = MEM_mallocN(sizeof(*cos)*numVerts, "vertexcos"); for (i=0,eve=em->verts.first; i<numVerts; i++,eve=eve->next) { - VECCOPY(cos[i], eve->co); + copy_v3_v3(cos[i], eve->co); } return cos; @@ -2654,7 +2655,7 @@ static void GetPosition(const SMikkTSpaceContext * pContext, float fPos[], const //assert(vert_index>=0 && vert_index<4); SGLSLMeshToTangent * pMesh = (SGLSLMeshToTangent *) pContext->m_pUserData; const float *co= pMesh->mvert[(&pMesh->mface[face_num].v1)[vert_index]].co; - VECCOPY(fPos, co); + copy_v3_v3(fPos, co); } static void GetTextureCoordinate(const SMikkTSpaceContext * pContext, float fUV[], const int face_num, const int vert_index) @@ -2680,7 +2681,7 @@ static void GetNormal(const SMikkTSpaceContext * pContext, float fNorm[], const const int smoothnormal = (pMesh->mface[face_num].flag & ME_SMOOTH); if(!smoothnormal) { // flat if(pMesh->precomputedFaceNormals) { - VECCOPY(fNorm, &pMesh->precomputedFaceNormals[3*face_num]); + copy_v3_v3(fNorm, &pMesh->precomputedFaceNormals[3*face_num]); } else { MFace *mf= &pMesh->mface[face_num]; @@ -2707,7 +2708,7 @@ static void SetTSpace(const SMikkTSpaceContext * pContext, const float fvTangent //assert(vert_index>=0 && vert_index<4); SGLSLMeshToTangent * pMesh = (SGLSLMeshToTangent *) pContext->m_pUserData; float * pRes = pMesh->tangent[4*face_num+iVert]; - VECCOPY(pRes, fvTangent); + copy_v3_v3(pRes, fvTangent); pRes[3]=fSign; } |