From 87d2ac96812fd30bcfcef34a8b78b9df8a72982e Mon Sep 17 00:00:00 2001 From: Bastien Montagne Date: Mon, 21 Sep 2020 14:43:29 +0200 Subject: Cleanup: move some paint helpers to ED_ 'namespace'. Those two functions had `BKE_` prefix, were defined in BKE headers, but implemented in ED code, yuck. Moved everything to ED area for now, since those do not look fondamental enough to belong to BKE, and none of their usages requires it currently. --- source/blender/editors/sculpt_paint/paint_image_proj.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'source/blender/editors/sculpt_paint/paint_image_proj.c') diff --git a/source/blender/editors/sculpt_paint/paint_image_proj.c b/source/blender/editors/sculpt_paint/paint_image_proj.c index 0c07b84426b..bc34efc44a2 100644 --- a/source/blender/editors/sculpt_paint/paint_image_proj.c +++ b/source/blender/editors/sculpt_paint/paint_image_proj.c @@ -6032,8 +6032,8 @@ static int texture_paint_camera_project_exec(bContext *C, wmOperator *op) return OPERATOR_CANCELLED; } - if (!BKE_paint_proj_mesh_data_check(scene, ob, &uvs, &mat, &tex, NULL)) { - BKE_paint_data_warning(op->reports, uvs, mat, tex, true); + if (!ED_paint_proj_mesh_data_check(scene, ob, &uvs, &mat, &tex, NULL)) { + ED_paint_data_warning(op->reports, uvs, mat, tex, true); WM_event_add_notifier(C, NC_SCENE | ND_TOOLSETTINGS, NULL); return OPERATOR_CANCELLED; } @@ -6290,7 +6290,7 @@ void PAINT_OT_image_from_view(wmOperatorType *ot) * Data generation for projective texturing * * *******************************************/ -void BKE_paint_data_warning(struct ReportList *reports, bool uvs, bool mat, bool tex, bool stencil) +void ED_paint_data_warning(struct ReportList *reports, bool uvs, bool mat, bool tex, bool stencil) { BKE_reportf(reports, RPT_WARNING, @@ -6303,7 +6303,7 @@ void BKE_paint_data_warning(struct ReportList *reports, bool uvs, bool mat, bool /* Make sure that active object has a material, * and assign UVs and image layers if they do not exist */ -bool BKE_paint_proj_mesh_data_check( +bool ED_paint_proj_mesh_data_check( Scene *scene, Object *ob, bool *uvs, bool *mat, bool *tex, bool *stencil) { Mesh *me; @@ -6614,7 +6614,7 @@ static bool proj_paint_add_slot(bContext *C, wmOperator *op) DEG_id_tag_update(&ma->id, ID_RECALC_SHADING); ED_area_tag_redraw(CTX_wm_area(C)); - BKE_paint_proj_mesh_data_check(scene, ob, NULL, NULL, NULL, NULL); + ED_paint_proj_mesh_data_check(scene, ob, NULL, NULL, NULL, NULL); return true; } @@ -6735,7 +6735,7 @@ static int add_simple_uvs_exec(bContext *C, wmOperator *UNUSED(op)) ED_uvedit_add_simple_uvs(bmain, scene, ob); - BKE_paint_proj_mesh_data_check(scene, ob, NULL, NULL, NULL, NULL); + ED_paint_proj_mesh_data_check(scene, ob, NULL, NULL, NULL, NULL); DEG_id_tag_update(ob->data, 0); WM_event_add_notifier(C, NC_GEOM | ND_DATA, ob->data); -- cgit v1.2.3