all repos — mgba @ fc550c792e10953e438db98f6c9f9dd0a8eb346b

mGBA Game Boy Advance Emulator

Video: Ensure FFmpeg encoder has audio frames
Jeffrey Pfau jeffrey@endrift.com
Tue, 23 Dec 2014 23:13:52 -0800
commit

fc550c792e10953e438db98f6c9f9dd0a8eb346b

parent

8d52bf7b28199d48ca6def1215cfe0f95b2045fc

2 files changed, 4 insertions(+), 0 deletions(-)

jump to
M CHANGESCHANGES

@@ -13,6 +13,7 @@ - GBA Memory: Properly initialize 1 Mb flash, and add debug logging

- Qt: Properly set default video recording settings - GBA Audio: Make larger buffer sizes than 2048 actually work properly - GBA Video: Fix blend issues with obscured middle layers + - Video: Ensure FFmpeg encoder has audio frames Misc: - Qt: Disable sync to video by default - GBA: Exit cleanly on FATAL if the port supports it
M src/platform/ffmpeg/ffmpeg-encoder.csrc/platform/ffmpeg/ffmpeg-encoder.c

@@ -225,6 +225,9 @@ encoder->audioFrame = av_frame_alloc();

#else encoder->audioFrame = avcodec_alloc_frame(); #endif + if (!encoder->audio->frame_size) { + encoder->audio->frame_size = 1024; + } encoder->audioFrame->nb_samples = encoder->audio->frame_size; encoder->audioFrame->format = encoder->audio->sample_fmt; encoder->audioFrame->pts = 0;