[Bf-blender-cvs] [df5f06cac22] master: GPencil: Close Box and Circle primitives with geometry
Antonioya
noreply at git.blender.org
Sat Jul 6 16:10:30 CEST 2019
Commit: df5f06cac2224498c9905ff3ea24811f46c09fa6
Author: Antonioya
Date: Sat Jul 6 16:10:21 2019 +0200
Branches: master
https://developer.blender.org/rBdf5f06cac2224498c9905ff3ea24811f46c09fa6
GPencil: Close Box and Circle primitives with geometry
Before the primitives were closed only with cyclic flag, but this doesn't create geometry for the gap. Now, a new geometry is created using close stroke function to have geometry for sculpt or edit.
===================================================================
M source/blender/editors/gpencil/gpencil_primitive.c
===================================================================
diff --git a/source/blender/editors/gpencil/gpencil_primitive.c b/source/blender/editors/gpencil/gpencil_primitive.c
index 21bee0a9d4e..540dd14fe1d 100644
--- a/source/blender/editors/gpencil/gpencil_primitive.c
+++ b/source/blender/editors/gpencil/gpencil_primitive.c
@@ -1284,6 +1284,11 @@ static void gpencil_primitive_interaction_end(bContext *C,
}
}
+ /* Close stroke with geometry */
+ if ((tgpi->type == GP_STROKE_BOX) || (tgpi->type == GP_STROKE_CIRCLE)) {
+ BKE_gpencil_close_stroke(gps);
+ }
+
DEG_id_tag_update(&tgpi->gpd->id, ID_RECALC_COPY_ON_WRITE);
DEG_id_tag_update(&tgpi->gpd->id, ID_RECALC_TRANSFORM | ID_RECALC_GEOMETRY);
More information about the Bf-blender-cvs
mailing list