Changeset View
Changeset View
Standalone View
Standalone View
source/blender/modifiers/intern/MOD_wave.cc
| Show First 20 Lines • Show All 146 Lines • ▼ Show 20 Lines | static void waveModifier_do(WaveModifierData *md, | ||||
| const float(*vert_normals)[3] = nullptr; | const float(*vert_normals)[3] = nullptr; | ||||
| if ((wmd->flag & MOD_WAVE_NORM) && (mesh != nullptr)) { | if ((wmd->flag & MOD_WAVE_NORM) && (mesh != nullptr)) { | ||||
| vert_normals = BKE_mesh_vertex_normals_ensure(mesh); | vert_normals = BKE_mesh_vertex_normals_ensure(mesh); | ||||
| } | } | ||||
| if (wmd->objectcenter != nullptr) { | if (wmd->objectcenter != nullptr) { | ||||
| float mat[4][4]; | float mat[4][4]; | ||||
| /* get the control object's location in local coordinates */ | /* get the control object's location in local coordinates */ | ||||
| invert_m4_m4(ob->imat, ob->obmat); | invert_m4_m4(ob->imat, ob->object_to_world); | ||||
| mul_m4_m4m4(mat, ob->imat, wmd->objectcenter->obmat); | mul_m4_m4m4(mat, ob->imat, wmd->objectcenter->object_to_world); | ||||
| wmd->startx = mat[3][0]; | wmd->startx = mat[3][0]; | ||||
| wmd->starty = mat[3][1]; | wmd->starty = mat[3][1]; | ||||
| } | } | ||||
| /* get the index of the deform group */ | /* get the index of the deform group */ | ||||
| MOD_get_vgroup(ob, mesh, wmd->defgrp_name, &dvert, &defgrp_index); | MOD_get_vgroup(ob, mesh, wmd->defgrp_name, &dvert, &defgrp_index); | ||||
| ▲ Show 20 Lines • Show All 334 Lines • Show Last 20 Lines | |||||