Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/editors/space_image/image_ops.c')
-rw-r--r--source/blender/editors/space_image/image_ops.c15
1 files changed, 8 insertions, 7 deletions
diff --git a/source/blender/editors/space_image/image_ops.c b/source/blender/editors/space_image/image_ops.c
index 4036f859231..78aaf957a87 100644
--- a/source/blender/editors/space_image/image_ops.c
+++ b/source/blender/editors/space_image/image_ops.c
@@ -3847,15 +3847,16 @@ void IMAGE_OT_clear_render_border(wmOperatorType *ot)
static bool do_fill_tile(PointerRNA *ptr, Image *ima, ImageTile *tile)
{
- float color[4];
- RNA_float_get_array(ptr, "color", color);
- int gen_type = RNA_enum_get(ptr, "generated_type");
- int width = RNA_int_get(ptr, "width");
- int height = RNA_int_get(ptr, "height");
+ RNA_float_get_array(ptr, "color", tile->gen_color);
+ tile->gen_type = RNA_enum_get(ptr, "generated_type");
+ tile->gen_x = RNA_int_get(ptr, "width");
+ tile->gen_y = RNA_int_get(ptr, "height");
bool is_float = RNA_boolean_get(ptr, "float");
- int planes = RNA_boolean_get(ptr, "alpha") ? 32 : 24;
- return BKE_image_fill_tile(ima, tile, width, height, color, gen_type, planes, is_float);
+ tile->gen_flag = is_float ? IMA_GEN_FLOAT : 0;
+ tile->gen_depth = RNA_boolean_get(ptr, "alpha") ? 32 : 24;
+
+ return BKE_image_fill_tile(ima, tile);
}
static void draw_fill_tile(PointerRNA *ptr, uiLayout *layout)