Fix #129353: GPv3: Crash when using Catmul-Rom curve type
Introduced by 5fff95f519.
The issue was that the `edit_points_vflag` buffer is of size `total_points_num`
which is based on the number of control points not evaluated positions.
The fix is to use `points_by_curve` instead of `points_by_curve_eval`
to get the right start and end indices.
Pull Request: https://projects.blender.org/blender/blender/pulls/129526
This commit is contained in:
@@ -827,8 +827,8 @@ static void grease_pencil_edit_batch_ensure(Object &object,
|
||||
positions_eval, range, layer_space_to_object_space, positions_eval_slice);
|
||||
});
|
||||
|
||||
for (const int curve_i : points_by_curve_eval.index_range()) {
|
||||
const IndexRange range = points_by_curve_eval[curve_i];
|
||||
for (const int curve_i : points_by_curve.index_range()) {
|
||||
const IndexRange range = points_by_curve[curve_i];
|
||||
edit_points_vflag[range.first()] |= GREASE_PENCIL_EDIT_STROKE_START;
|
||||
edit_points_vflag[range.last()] |= GREASE_PENCIL_EDIT_STROKE_END;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user