all repos — mgba @ c7035f6c347423dc0a13ca5e72a002448758f87e

mGBA Game Boy Advance Emulator

FFmpeg: Add ZMBV specialization
Vicki Pfau vi@endrift.com
Thu, 23 Jul 2020 19:37:54 -0700
commit

c7035f6c347423dc0a13ca5e72a002448758f87e

parent

7ecdf94b6beb5c5a78d59b9822067bb253368595

1 files changed, 6 insertions(+), 0 deletions(-)

jump to
M src/feature/ffmpeg/ffmpeg-encoder.csrc/feature/ffmpeg/ffmpeg-encoder.c

@@ -402,6 +402,12 @@

if (encoder->video->codec->id == AV_CODEC_ID_PNG) { encoder->video->compression_level = 8; } +#if LIBAVCODEC_VERSION_INT >= AV_VERSION_INT(58, 48, 100) + if (encoder->video->codec->id == AV_CODEC_ID_ZMBV) { + encoder->video->compression_level = 5; + encoder->video->pix_fmt = AV_PIX_FMT_BGR0; + } +#endif if (strcmp(vcodec->name, "libx264") == 0) { // Try to adaptively figure out when you can use a slower encoder if (encoder->width * encoder->height > 1000000) {