Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/mask/mask_query.c
| Show First 20 Lines • Show All 632 Lines • ▼ Show 20 Lines | for (MaskSpline *spline = mask_layer->splines.first; spline != NULL; spline = spline->next) { | ||||
| const MaskSplinePoint *deform_point = &points_array[i]; | const MaskSplinePoint *deform_point = &points_array[i]; | ||||
| const BezTriple *bezt = &point->bezt; | const BezTriple *bezt = &point->bezt; | ||||
| float handle[2]; | float handle[2]; | ||||
| if (!MASKPOINT_ISSEL_ANY(point)) { | if (!MASKPOINT_ISSEL_ANY(point)) { | ||||
| continue; | continue; | ||||
| } | } | ||||
| if (bezt->f2 & SELECT) { | if (bezt->f2 & SELECT) { | ||||
| minmax_v2v2_v2(min, max, deform_point->bezt.vec[1]); | minmax_v2v2_v2(min, max, deform_point->bezt.vec[1]); | ||||
| ok = true; | |||||
| } | } | ||||
| if (BKE_mask_point_handles_mode_get(point) == MASK_HANDLE_MODE_STICK) { | if (BKE_mask_point_handles_mode_get(point) == MASK_HANDLE_MODE_STICK) { | ||||
| BKE_mask_point_handle(deform_point, MASK_WHICH_HANDLE_STICK, handle); | BKE_mask_point_handle(deform_point, MASK_WHICH_HANDLE_STICK, handle); | ||||
| minmax_v2v2_v2(min, max, handle); | minmax_v2v2_v2(min, max, handle); | ||||
| ok = true; | |||||
| } | } | ||||
| else { | else { | ||||
| if ((bezt->f1 & SELECT) && (bezt->h1 != HD_VECT)) { | if ((bezt->f1 & SELECT) && (bezt->h1 != HD_VECT)) { | ||||
| BKE_mask_point_handle(deform_point, MASK_WHICH_HANDLE_LEFT, handle); | BKE_mask_point_handle(deform_point, MASK_WHICH_HANDLE_LEFT, handle); | ||||
| minmax_v2v2_v2(min, max, handle); | minmax_v2v2_v2(min, max, handle); | ||||
| ok = true; | |||||
| } | } | ||||
| if ((bezt->f3 & SELECT) && (bezt->h2 != HD_VECT)) { | if ((bezt->f3 & SELECT) && (bezt->h2 != HD_VECT)) { | ||||
| BKE_mask_point_handle(deform_point, MASK_WHICH_HANDLE_RIGHT, handle); | BKE_mask_point_handle(deform_point, MASK_WHICH_HANDLE_RIGHT, handle); | ||||
| minmax_v2v2_v2(min, max, handle); | minmax_v2v2_v2(min, max, handle); | ||||
| ok = true; | |||||
| } | } | ||||
| } | } | ||||
| ok = true; | |||||
| } | } | ||||
| } | } | ||||
| } | } | ||||
| return ok; | return ok; | ||||
| } | } | ||||
| /** \} */ | /** \} */ | ||||
| ▲ Show 20 Lines • Show All 176 Lines • Show Last 20 Lines | |||||