change pixel format from BGRA to BGR0

for this kind of footage carrying alpha information makes no sense, and it additionally complicates things by hugely damaging compatibility of the resulting video. after this change alone the video becomes compatible with VfW/WinAPI and tools that rely on it (avisynth, virtualdub).

fixes https://bugs.dolphin-emu.org/issues/11141 and https://bugs.dolphin-emu.org/issues/10193
This commit is contained in:
feos 2019-03-11 01:29:34 +03:00
parent 909e9322e7
commit 005e60fa22
1 changed files with 1 additions and 1 deletions

View File

@ -191,7 +191,7 @@ bool AVIDump::CreateVideoFile()
s_codec_context->time_base.num = 1; s_codec_context->time_base.num = 1;
s_codec_context->time_base.den = VideoInterface::GetTargetRefreshRate(); s_codec_context->time_base.den = VideoInterface::GetTargetRefreshRate();
s_codec_context->gop_size = 12; s_codec_context->gop_size = 12;
s_codec_context->pix_fmt = g_Config.bUseFFV1 ? AV_PIX_FMT_BGRA : AV_PIX_FMT_YUV420P; s_codec_context->pix_fmt = g_Config.bUseFFV1 ? AV_PIX_FMT_BGR0 : AV_PIX_FMT_YUV420P;
if (output_format->flags & AVFMT_GLOBALHEADER) if (output_format->flags & AVFMT_GLOBALHEADER)
s_codec_context->flags |= AV_CODEC_FLAG_GLOBAL_HEADER; s_codec_context->flags |= AV_CODEC_FLAG_GLOBAL_HEADER;