Update common-c with colorspace configuration support

This commit is contained in:
Cameron Gutman 2019-12-14 14:40:02 -08:00
parent bf52d3189d
commit af6b8c9b88
2 changed files with 13 additions and 1 deletions

View file

@ -282,6 +282,18 @@ void SdlRenderer::renderFrame(AVFrame* frame)
goto Exit;
}
switch (frame->colorspace)
{
case AVCOL_SPC_BT709:
SDL_SetYUVConversionMode(SDL_YUV_CONVERSION_BT709);
break;
case AVCOL_SPC_BT470BG:
case AVCOL_SPC_SMPTE170M:
default:
SDL_SetYUVConversionMode(SDL_YUV_CONVERSION_BT601);
break;
}
m_Texture = SDL_CreateTexture(m_Renderer,
sdlFormat,
SDL_TEXTUREACCESS_STREAMING,

@ -1 +1 @@
Subproject commit f5ae5df5d0689084293dbce3c20a6ff2322c9c2c
Subproject commit e60a7ef75f02559e7c5271f4e08f815af5f4a8cc