]> granicus.if.org Git - libvpx/commitdiff
rd_pick_palette_intra_sbuv: fix implicit float conv
authorJames Zern <jzern@google.com>
Fri, 22 Jul 2016 20:21:55 +0000 (13:21 -0700)
committerJames Zern <jzern@google.com>
Sat, 23 Jul 2016 01:08:23 +0000 (18:08 -0700)
float->int as reported by -Wfloat-conversion

Change-Id: I9e3d6ce9dbb0689f214afc8d5950f209275e883d

vp10/encoder/rdopt.c

index b667fcf8552c3a9315da2beb77ecbed87b6d22a5..d5a793903e1161861c2c5498ef8727c988858581 100644 (file)
@@ -3817,12 +3817,12 @@ static void rd_pick_palette_intra_sbuv(VP10_COMP *cpi, MACROBLOCK *x,
 #if CONFIG_VP9_HIGHBITDEPTH
           if (cpi->common.use_highbitdepth)
             pmi->palette_colors[i * PALETTE_MAX_SIZE + j] =
-                clip_pixel_highbd(roundf(centroids[j * 2 + i - 1]),
+                clip_pixel_highbd((int)lroundf(centroids[j * 2 + i - 1]),
                                   cpi->common.bit_depth);
           else
 #endif  // CONFIG_VP9_HIGHBITDEPTH
             pmi->palette_colors[i * PALETTE_MAX_SIZE + j] =
-                clip_pixel(roundf(centroids[j * 2 + i - 1]));
+                clip_pixel((int)lroundf(centroids[j * 2 + i - 1]));
         }
       }
       for (r = 0; r < rows; ++r)