]> git.sesse.net Git - ffmpeg/blobdiff - libswscale/swscale.c
lavu: Drop the {minus,plus}1 suffix from AVComponentDescriptor fields
[ffmpeg] / libswscale / swscale.c
index f6427bfb55db48604e9ea1c93bba67b2aadcfc93..2f9cb1b453d2da8995b41cc4eabd6d9abd8775b5 100644 (file)
@@ -91,7 +91,7 @@ static void hScale16To19_c(SwsContext *c, int16_t *_dst, int dstW,
     int i;
     int32_t *dst        = (int32_t *) _dst;
     const uint16_t *src = (const uint16_t *) _src;
-    int bits            = desc->comp[0].depth_minus1;
+    int bits            = desc->comp[0].depth - 1;
     int sh              = bits - 4;
 
     for (i = 0; i < dstW; i++) {
@@ -114,7 +114,7 @@ static void hScale16To15_c(SwsContext *c, int16_t *dst, int dstW,
     const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(c->srcFormat);
     int i;
     const uint16_t *src = (const uint16_t *) _src;
-    int sh              = desc->comp[0].depth_minus1;
+    int sh              = desc->comp[0].depth - 1;
 
     for (i = 0; i < dstW; i++) {
         int j;
@@ -699,8 +699,7 @@ static int swscale(SwsContext *c, const uint8_t *src[],
         if (is9_OR_10BPS(dstFormat)) {
             const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(dstFormat);
             fill_plane9or10(dst[3], dstStride[3], length, height, lastDstY,
-                            255, desc->comp[3].depth_minus1 + 1,
-                            isBE(dstFormat));
+                            255, desc->comp[3].depth, isBE(dstFormat));
         } else
             fillPlane(dst[3], dstStride[3], length, height, lastDstY, 255);
     }