FFmpeg: Fix GIF recording (fixes #2393)

This commit is contained in:
Vicki Pfau 2022-01-20 23:49:56 -08:00
parent fff87985fe
commit 8a310dcfed
2 changed files with 2 additions and 1 deletions

View File

@ -25,6 +25,7 @@ Emulation fixes:
Other fixes:
- Core: Don't attempt to restore rewind diffs past start of rewind
- FFmpeg: Fix crash when encoding audio with some containers
- FFmpeg: Fix GIF recording (fixes mgba.io/i/2393)
- GB: Fix temporary saves
- GB, GBA: Save writeback-pending masked saves on unload (fixes mgba.io/i/2396)
Misc:

View File

@ -785,7 +785,7 @@ void _ffmpegPostVideoFrame(struct mAVStream* stream, const color_t* pixels, size
sws_scale(encoder->scaleContext, (const uint8_t* const*) &pixels, (const int*) &stride, 0, encoder->iheight, encoder->videoFrame->data, encoder->videoFrame->linesize);
if (encoder->graph) {
if (av_buffersrc_add_frame(encoder->source, encoder->videoFrame) < 0) {
if (av_buffersrc_write_frame(encoder->source, encoder->videoFrame) < 0) {
return;
}
while (true) {