GPencil: Fix unreported set origin from Python
The set origin was not working from python because the operator was checking if the stroke was valid in the console area. As the stroke only can be valid for GP obects, this check is not needed.
This commit is contained in:
@@ -1355,11 +1355,6 @@ static int object_origin_set_exec(bContext *C, wmOperator *op)
|
||||
invert_m4_m4(inverse_diff_mat, diff_mat);
|
||||
for (bGPDframe *gpf = gpl->frames.first; gpf; gpf = gpf->next) {
|
||||
for (bGPDstroke *gps = gpf->strokes.first; gps; gps = gps->next) {
|
||||
/* skip strokes that are invalid for current view */
|
||||
if (ED_gpencil_stroke_can_use(C, gps) == false) {
|
||||
continue;
|
||||
}
|
||||
|
||||
for (i = 0, pt = gps->points; i < gps->totpoints; i++, pt++) {
|
||||
float mpt[3];
|
||||
mul_v3_m4v3(mpt, inverse_diff_mat, &pt->x);
|
||||
|
||||
Reference in New Issue
Block a user