On Thu, 24 Feb 2022, Michael Niedermayer wrote:

On Wed, Feb 23, 2022 at 09:45:53PM +0200, Martin Storsjö wrote:
The range parameters need to be set up before calling
sws_init_context (which selects which fastpaths can be used;
this gets called by sws_getContext); solely passing them via
sws_setColorspaceDetails isn't enough.

This fixes producing full range YUV range output when doing
YUV->YUV conversions between different YUV color spaces.

Signed-off-by: Martin Storsjö <mar...@martin.st>
---
 libswscale/utils.c                | 11 ++++++++---
 tests/fate/libswscale.mak         | 16 ++++++++++++++++
 tests/ref/fate/sws-yuv-colorspace |  6 ++++++
 tests/ref/fate/sws-yuv-range      |  6 ++++++
 4 files changed, 36 insertions(+), 3 deletions(-)
 create mode 100644 tests/ref/fate/sws-yuv-colorspace
 create mode 100644 tests/ref/fate/sws-yuv-range

LGTM

tested on mingw32/64 + wine / linux x86 32/64bit, arm/mips qemu

Thanks, pushed!

// Martin
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Reply via email to