Commit: 3803c646d8e8277d4d51473b03ac3153646a3493
Author: Sergey Sharybin
Date:   Wed Apr 30 17:39:14 2014 +0600
https://developer.blender.org/rB3803c646d8e8277d4d51473b03ac3153646a3493

Changes to cache line display in image editor

Only show it when having active mask or when current image
is a sequence or movie.

===================================================================

M       source/blender/editors/space_image/image_draw.c

===================================================================

diff --git a/source/blender/editors/space_image/image_draw.c 
b/source/blender/editors/space_image/image_draw.c
index 4e1b601..635c7cd 100644
--- a/source/blender/editors/space_image/image_draw.c
+++ b/source/blender/editors/space_image/image_draw.c
@@ -888,6 +888,17 @@ void draw_image_main(const bContext *C, ARegion *ar)
                draw_render_info(sima->iuser.scene, ima, ar, zoomx, zoomy);
 }
 
+static bool show_image_cache(Image *image, Mask *mask)
+{
+       if (image == NULL && mask == NULL) {
+               return false;
+       }
+       if (mask == NULL) {
+               return ELEM(image->source, IMA_SRC_SEQUENCE, IMA_SRC_MOVIE);
+       }
+       return true;
+}
+
 void draw_image_cache(const bContext *C, ARegion *ar)
 {
        SpaceImage *sima = CTX_wm_space_image(C);
@@ -900,7 +911,7 @@ void draw_image_cache(const bContext *C, ARegion *ar)
                mask = ED_space_image_get_mask(sima);
        }
 
-       if (image == NULL && mask == NULL) {
+       if (!show_image_cache(image, mask)) {
                return;
        }

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to