Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/sculpt_paint/sculpt_multiplane_scrape.c
| Show First 20 Lines • Show All 265 Lines • ▼ Show 20 Lines | if (is_zero_v3(ss->cache->grab_delta_symmetry)) { | ||||
| return; | return; | ||||
| } | } | ||||
| mul_v3_v3v3(temp, area_no_sp, ss->cache->scale); | mul_v3_v3v3(temp, area_no_sp, ss->cache->scale); | ||||
| mul_v3_fl(temp, displace); | mul_v3_fl(temp, displace); | ||||
| add_v3_v3(area_co, temp); | add_v3_v3(area_co, temp); | ||||
| /* Init brush local space matrix. */ | /* Init brush local space matrix. */ | ||||
| cross_v3_v3v3(mat[0], area_no, ss->cache->grab_delta_symmetry); | SCULPT_stroke_local_space_matrix_init( | ||||
| mat[0][3] = 0.0f; | mat, ss->cache->location, area_no, ss->cache->grab_delta_symmetry); | ||||
| cross_v3_v3v3(mat[1], area_no, mat[0]); | |||||
| mat[1][3] = 0.0f; | |||||
| copy_v3_v3(mat[2], area_no); | |||||
| mat[2][3] = 0.0f; | |||||
| copy_v3_v3(mat[3], ss->cache->location); | |||||
| mat[3][3] = 1.0f; | |||||
| normalize_m4(mat); | |||||
| invert_m4(mat); | invert_m4(mat); | ||||
| /* Update matrix for the cursor preview. */ | /* Update matrix for the cursor preview. */ | ||||
| if (ss->cache->mirror_symmetry_pass == 0 && ss->cache->radial_symmetry_pass == 0) { | if (ss->cache->mirror_symmetry_pass == 0 && ss->cache->radial_symmetry_pass == 0) { | ||||
| copy_m4_m4(ss->cache->stroke_local_mat, mat); | copy_m4_m4(ss->cache->stroke_local_mat, mat); | ||||
| } | } | ||||
| /* Dynamic mode. */ | /* Dynamic mode. */ | ||||
| ▲ Show 20 Lines • Show All 174 Lines • Show Last 20 Lines | |||||