From d8fdcbb92dc03b83233290da7f57ebeba1ab0afb Mon Sep 17 00:00:00 2001 From: Hendrik Leppkes Date: Sun, 15 Dec 2013 11:54:18 +0100 Subject: Fix v210 with an odd image width. --- decoder/LAVVideo/pixconv/convert_generic.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'decoder/LAVVideo/pixconv/convert_generic.cpp') diff --git a/decoder/LAVVideo/pixconv/convert_generic.cpp b/decoder/LAVVideo/pixconv/convert_generic.cpp index 2f5e4d8f..234b947a 100644 --- a/decoder/LAVVideo/pixconv/convert_generic.cpp +++ b/decoder/LAVVideo/pixconv/convert_generic.cpp @@ -584,6 +584,10 @@ HRESULT CLAVPixFmtConverter::ConvertTov210(const uint8_t* const src[4], const in // Calculate v210 stride int outStride = (((dstStride[0] >> 2) + 47) / 48) * 128; + // Align width to an even number for processing + // This may read into the source stride, but otherwise the algorithm won't work. + width = FFALIGN(width, 2); + BYTE *pdst = dst[0]; int32_t *p = (int32_t *)pdst; int w; -- cgit v1.2.3