[Bf-blender-cvs] [cb385abfe76] greasepencil-refactor: GPencil: Remove unused parameter
Antonio Vazquez
noreply at git.blender.org
Wed Jan 8 17:31:09 CET 2020
Commit: cb385abfe76fda39f9722f1f7f732d8462c38a7e
Author: Antonio Vazquez
Date: Wed Jan 8 17:30:49 2020 +0100
Branches: greasepencil-refactor
https://developer.blender.org/rBcb385abfe76fda39f9722f1f7f732d8462c38a7e
GPencil: Remove unused parameter
===================================================================
M source/blender/blenkernel/BKE_gpencil.h
M source/blender/blenkernel/intern/gpencil.c
M source/blender/editors/gpencil/gpencil_paint.c
M source/blender/editors/gpencil/gpencil_primitive.c
M source/blender/editors/gpencil/gpencil_utils.c
===================================================================
diff --git a/source/blender/blenkernel/BKE_gpencil.h b/source/blender/blenkernel/BKE_gpencil.h
index dce44a514da..fed902a0183 100644
--- a/source/blender/blenkernel/BKE_gpencil.h
+++ b/source/blender/blenkernel/BKE_gpencil.h
@@ -259,7 +259,7 @@ void BKE_gpencil_recalc_geometry_caches(struct Object *ob,
struct bGPDlayer *gpl,
struct MaterialGPencilStyle *gp_style,
struct bGPDstroke *gps);
-void BKE_gpencil_calc_stroke_uv(struct Object *ob, struct bGPDstroke *gps);
+void BKE_gpencil_calc_stroke_uv(struct bGPDstroke *gps);
void BKE_gpencil_transform(struct bGPdata *gpd, float mat[4][4]);
diff --git a/source/blender/blenkernel/intern/gpencil.c b/source/blender/blenkernel/intern/gpencil.c
index 96c62802b50..ec0ce38ec3e 100644
--- a/source/blender/blenkernel/intern/gpencil.c
+++ b/source/blender/blenkernel/intern/gpencil.c
@@ -2789,7 +2789,7 @@ void BKE_gpencil_triangulate_stroke_fill(bGPdata *gpd, bGPDstroke *gps)
}
/* texture coordinate utilities */
-void BKE_gpencil_calc_stroke_uv(Object *ob, bGPDstroke *gps)
+void BKE_gpencil_calc_stroke_uv(bGPDstroke *gps)
{
if (gps == NULL || gps->totpoints == 0) {
return;
@@ -2821,7 +2821,7 @@ void BKE_gpencil_recalc_geometry_caches(Object *ob,
}
/* calc uv data along the stroke */
- BKE_gpencil_calc_stroke_uv(ob, gps);
+ BKE_gpencil_calc_stroke_uv(gps);
/* clear flag */
gps->flag &= ~GP_STROKE_RECALC_GEOMETRY;
@@ -3819,4 +3819,4 @@ void BKE_gpencil_visible_stroke_iter(
}
}
-/** \} */
\ No newline at end of file
+/** \} */
diff --git a/source/blender/editors/gpencil/gpencil_paint.c b/source/blender/editors/gpencil/gpencil_paint.c
index 0a47e08b367..e35d1f54865 100644
--- a/source/blender/editors/gpencil/gpencil_paint.c
+++ b/source/blender/editors/gpencil/gpencil_paint.c
@@ -1180,7 +1180,7 @@ static void gp_stroke_newfrombuffer(tGPsdata *p)
}
/* calculate UVs along the stroke */
- BKE_gpencil_calc_stroke_uv(obact, gps);
+ BKE_gpencil_calc_stroke_uv(gps);
/* add stroke to frame, usually on tail of the listbase, but if on back is enabled the stroke
* is added on listbase head because the drawing order is inverse and the head stroke is the
diff --git a/source/blender/editors/gpencil/gpencil_primitive.c b/source/blender/editors/gpencil/gpencil_primitive.c
index eef51feebbc..61f5dbfe270 100644
--- a/source/blender/editors/gpencil/gpencil_primitive.c
+++ b/source/blender/editors/gpencil/gpencil_primitive.c
@@ -1005,7 +1005,8 @@ static void gp_primitive_update_strokes(bContext *C, tGPDprimitive *tgpi)
/* get origin to reproject point */
float origin[3];
- ED_gpencil_drawing_reference_get(tgpi->scene, tgpi->ob, tgpi->gpl, ts->gpencil_v3d_align, origin);
+ ED_gpencil_drawing_reference_get(
+ tgpi->scene, tgpi->ob, tgpi->gpl, ts->gpencil_v3d_align, origin);
/* reproject current */
ED_gpencil_tpoint_to_point(tgpi->ar, origin, tpt, &spt);
ED_gp_project_point_to_plane(
@@ -1074,7 +1075,8 @@ static void gp_primitive_update_strokes(bContext *C, tGPDprimitive *tgpi)
/* reproject to plane */
if (!is_depth) {
float origin[3];
- ED_gpencil_drawing_reference_get(tgpi->scene, tgpi->ob, tgpi->gpl, ts->gpencil_v3d_align, origin);
+ ED_gpencil_drawing_reference_get(
+ tgpi->scene, tgpi->ob, tgpi->gpl, ts->gpencil_v3d_align, origin);
ED_gp_project_stroke_to_plane(
tgpi->scene, tgpi->ob, tgpi->rv3d, gps, origin, ts->gp_sculpt.lock_axis - 1);
}
@@ -1344,7 +1346,7 @@ static void gpencil_primitive_interaction_end(bContext *C,
gps->tot_triangles = 0;
/* calculate UVs along the stroke */
- BKE_gpencil_calc_stroke_uv(tgpi->ob, gps);
+ BKE_gpencil_calc_stroke_uv(gps);
}
/* transfer stroke from temporary buffer to the actual frame */
diff --git a/source/blender/editors/gpencil/gpencil_utils.c b/source/blender/editors/gpencil/gpencil_utils.c
index 8776fd64965..0639c9dad32 100644
--- a/source/blender/editors/gpencil/gpencil_utils.c
+++ b/source/blender/editors/gpencil/gpencil_utils.c
@@ -2029,7 +2029,7 @@ void ED_gpencil_update_color_uv(Main *bmain, Material *mat)
gps_ma = BKE_material_gpencil_get(ob, gps->mat_nr + 1);
/* update */
if ((gps_ma) && (gps_ma == mat)) {
- BKE_gpencil_calc_stroke_uv(ob, gps);
+ BKE_gpencil_calc_stroke_uv(gps);
}
}
}
More information about the Bf-blender-cvs
mailing list