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')
-rw-r--r--source/blender/editors/space_image/image_buttons.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/source/blender/editors/space_image/image_buttons.c b/source/blender/editors/space_image/image_buttons.c
index 270fe0c59dc..f4688ce17fd 100644
--- a/source/blender/editors/space_image/image_buttons.c
+++ b/source/blender/editors/space_image/image_buttons.c
@@ -980,6 +980,16 @@ void uiTemplateImage(uiLayout *layout,
bool is_data = IMB_colormanagement_space_name_is_data(ima->colorspace_settings.name);
uiLayoutSetActive(sub, !is_data);
}
+
+ if (ima && iuser) {
+ void *lock;
+ ImBuf *ibuf = BKE_image_acquire_ibuf(ima, iuser, &lock);
+
+ if (ibuf->rect_float && (ibuf->flags & IB_halffloat) == 0) {
+ uiItemR(col, &imaptr, "use_half_precision", 0, NULL, ICON_NONE);
+ }
+ BKE_image_release_ibuf(ima, ibuf, lock);
+ }
}
uiItemR(col, &imaptr, "use_view_as_render", 0, NULL, ICON_NONE);