diff options
author | Hendrik Leppkes <h.leppkes@gmail.com> | 2015-09-08 15:43:03 +0200 |
---|---|---|
committer | Hendrik Leppkes <h.leppkes@gmail.com> | 2015-09-08 16:35:28 +0200 |
commit | 151aa2ebff514a9d150a2d3a7b92be1dcc46df36 (patch) | |
tree | 866bd99edecd778aee4cd8eb5f34977d0c82a27d /libswscale/swscale_unscaled.c | |
parent | f53569a93f853057d4852601b547a1d9c57613b6 (diff) | |
parent | 2268db2cd052674fde55c7d48b7a5098ce89b4ba (diff) | |
download | ffmpeg-151aa2ebff514a9d150a2d3a7b92be1dcc46df36.tar.gz |
Merge commit '2268db2cd052674fde55c7d48b7a5098ce89b4ba'
* commit '2268db2cd052674fde55c7d48b7a5098ce89b4ba':
lavu: Drop the {minus,plus}1 suffix from AVComponentDescriptor fields
Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
Diffstat (limited to 'libswscale/swscale_unscaled.c')
-rw-r--r-- | libswscale/swscale_unscaled.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/libswscale/swscale_unscaled.c b/libswscale/swscale_unscaled.c index 18baaead35..8f57b2a3d2 100644 --- a/libswscale/swscale_unscaled.c +++ b/libswscale/swscale_unscaled.c @@ -1417,7 +1417,7 @@ static int planarCopyWrapper(SwsContext *c, const uint8_t *src[], if (!src[plane] || (plane == 1 && !src[2])) { if (is16BPS(c->dstFormat) || isNBPS(c->dstFormat)) { fillPlane16(dst[plane], dstStride[plane], length, height, y, - plane == 3, desc_dst->comp[plane].depth_minus1, + plane == 3, desc_dst->comp[plane].depth, isBE(c->dstFormat)); } else { fillPlane(dst[plane], dstStride[plane], length, height, y, @@ -1427,8 +1427,8 @@ static int planarCopyWrapper(SwsContext *c, const uint8_t *src[], if(isNBPS(c->srcFormat) || isNBPS(c->dstFormat) || (is16BPS(c->srcFormat) != is16BPS(c->dstFormat)) ) { - const int src_depth = desc_src->comp[plane].depth_minus1 + 1; - const int dst_depth = desc_dst->comp[plane].depth_minus1 + 1; + const int src_depth = desc_src->comp[plane].depth; + const int dst_depth = desc_dst->comp[plane].depth; const uint16_t *srcPtr2 = (const uint16_t *) srcPtr; uint16_t *dstPtr2 = (uint16_t*)dstPtr; @@ -1543,7 +1543,7 @@ static int planarCopyWrapper(SwsContext *c, const uint8_t *src[], } else { if (is16BPS(c->srcFormat) && is16BPS(c->dstFormat)) length *= 2; - else if (!desc_src->comp[0].depth_minus1) + else if (desc_src->comp[0].depth == 1) length >>= 3; // monowhite/black for (i = 0; i < height; i++) { memcpy(dstPtr, srcPtr, length); @@ -1648,7 +1648,7 @@ void ff_get_unscaled_swscale(SwsContext *c) dstFormat == AV_PIX_FMT_BGRA64LE || dstFormat == AV_PIX_FMT_BGRA64BE)) c->swscale = planarRgb16ToRgb16Wrapper; - if (av_pix_fmt_desc_get(srcFormat)->comp[0].depth_minus1 == 7 && + if (av_pix_fmt_desc_get(srcFormat)->comp[0].depth == 8 && isPackedRGB(srcFormat) && dstFormat == AV_PIX_FMT_GBRP) c->swscale = rgbToPlanarRgbWrapper; |