Merge branch 'tizen' into sandbox/cyeon/devel
[platform/core/uifw/libtdm.git] / tools / buffers.c
index 5cf58ef..ea88179 100644 (file)
@@ -254,8 +254,12 @@ fill_smpte_yuv_planar(const struct yuv_info *yuv,
                for (; x < width * 6 / 7; ++x)
                        y_mem[x] = colors_bottom[(x - width * 5 / 7) * 3
                                                                         / (width / 7) + 4].y;
-               for (; x < width; ++x)
-                       y_mem[x] = colors_bottom[7].y;
+               for (; x < width; ++x) {
+                       if (rand_r(&rand_seed) % 2)
+                               y_mem[x] = colors_bottom[1].y;
+                       else
+                               y_mem[x] = colors_bottom[7].y;
+               }
                y_mem += stride;
        }
 
@@ -292,8 +296,13 @@ fill_smpte_yuv_planar(const struct yuv_info *yuv,
                                                                                                 3 / (width / 7) + 4].v;
                }
                for (; x < width; x += xsub) {
-                       u_mem[x * cs / xsub] = colors_bottom[7].u;
-                       v_mem[x * cs / xsub] = colors_bottom[7].v;
+                       if (rand_r(&rand_seed) % 2) {
+                               u_mem[x * cs / xsub] = colors_bottom[1].u;
+                               v_mem[x * cs / xsub] = colors_bottom[1].v;
+                       } else {
+                               u_mem[x * cs / xsub] = colors_bottom[7].u;
+                               v_mem[x * cs / xsub] = colors_bottom[7].v;
+                       }
                }
                u_mem += stride * cs / xsub;
                v_mem += stride * cs / xsub;