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>2019-08-21 23:28:35 +0300
committerCampbell Barton <ideasman42@gmail.com>2019-08-21 23:48:10 +0300
commit189aa32a3ac0e949275d16ffb19576a1306d1780 (patch)
treeff75826925b4b26f6b4aa8928fe3c5d3c799a98f /source/blender/blenkernel/intern/crazyspace.c
parent4a2d1953f3ca3e1160a3ce767df15e481658bdf6 (diff)
Cleanup: vertex coordinate access, naming & minor changes
This also splits vertex access and allocation so it's possible to copy coordinates into an existing array without allocating it.
Diffstat (limited to 'source/blender/blenkernel/intern/crazyspace.c')
-rw-r--r--source/blender/blenkernel/intern/crazyspace.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/blenkernel/intern/crazyspace.c b/source/blender/blenkernel/intern/crazyspace.c
index 09bbc6c0d13..fcbebd24b4a 100644
--- a/source/blender/blenkernel/intern/crazyspace.c
+++ b/source/blender/blenkernel/intern/crazyspace.c
@@ -293,7 +293,7 @@ int BKE_crazyspace_get_first_deform_matrices_editbmesh(struct Depsgraph *depsgra
BLI_linklist_free((LinkNode *)datamasks, NULL);
me = BKE_mesh_from_editmesh_with_coords_thin_wrap(em, &data_mask, NULL);
- deformedVerts = editbmesh_get_vertex_cos(em, &numVerts);
+ deformedVerts = editbmesh_vert_coords_alloc(em, &numVerts);
defmats = MEM_mallocN(sizeof(*defmats) * numVerts, "defmats");
for (a = 0; a < numVerts; a++) {
@@ -383,7 +383,7 @@ int BKE_sculpt_get_first_deform_matrices(struct Depsgraph *depsgraph,
* state. */
Mesh *me = object_eval.data;
me_eval = BKE_mesh_copy_for_eval(me, true);
- deformedVerts = BKE_mesh_vertexCos_get(me, &numVerts);
+ deformedVerts = BKE_mesh_vert_coords_alloc(me, &numVerts);
defmats = MEM_callocN(sizeof(*defmats) * numVerts, "defmats");
for (a = 0; a < numVerts; a++) {
@@ -485,7 +485,7 @@ void BKE_crazyspace_build_sculpt(struct Depsgraph *depsgraph,
int a, numVerts;
Mesh *mesh = (Mesh *)object->data;
- *deformcos = BKE_mesh_vertexCos_get(mesh, &numVerts);
+ *deformcos = BKE_mesh_vert_coords_alloc(mesh, &numVerts);
*deformmats = MEM_callocN(sizeof(*(*deformmats)) * numVerts, "defmats");
for (a = 0; a < numVerts; a++) {