[FFmpeg-devel] [PATCH] libswscale/swscale_unscaled.c: UHD Resolution Performance Increase for Color Space Convertions / NVENC Related
h.leppkes at gmail.com
Mon Oct 3 13:28:33 EEST 2016
On Mon, Oct 3, 2016 at 11:35 AM, Ali KIZIL <alikizil at gmail.com> wrote:
> This patch is done for performance increase on UHD or above resolution
> color space convertions.
> Some SDI sources provide yuv422p10 for 10bit source and uyvy422 for 8 bit
> To encode these sources with NVENC 10 bits, there is a need to convert
> these color spaces to P010.
> Before patch for UHD and above resolutions, convertion could not exceed
> ~25-30 fps, which can not be used for a 50 fps encoding.
> This patch fixes this problem.
> Also, color space convertion speed for 10bit YUV422P to 8bit YUV420P is
> having the same problem.
> If anybody wants to encode 10 bits source in 8 bits for UHD or above
> resolutions could not achive high frame rate ratio as well.
> This patch also fixes this problem.
> I think it will be good to apply this patch to avoid performance loss in
> high resolutions.
These conversion functions butcher quality by using only every second
row of chroma for 422 -> 420 conversions without any interpolation,
and they don't dither for 10->8 bit conversions.
Not sure its a good idea to do that, even more so without an option to
defeat these low-quality variants with the swscale flags.
More information about the ffmpeg-devel