summaryrefslogtreecommitdiff
path: root/Source/Core
diff options
context:
space:
mode:
authorPierre Bourdon <delroth@gmail.com>2014-07-10 02:53:12 +0200
committerPierre Bourdon <delroth@gmail.com>2014-07-10 02:53:12 +0200
commitda697df6ee2e166adc732925438d611963ca3a08 (patch)
tree0c027d3f26f77941f7fada2546a38a954763d5b9 /Source/Core
parent29873a7c55aef0fe9c461df459671ba43c9f7c17 (diff)
AVIDump: fix FFV1 encoding
ffmpeg 2.0 changed requirements for the FFV1 encoder and made them more strict, requiring more fields of the input frame to be initialized. Explicitly setting pixfmt, width and height solve the EINVAL issues with FFV1 encoding. Original fix from http://ffmpeg.org/pipermail/libav-user/2013-October/005759.html
Diffstat (limited to 'Source/Core')
-rw-r--r--Source/Core/VideoCommon/AVIDump.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/Source/Core/VideoCommon/AVIDump.cpp b/Source/Core/VideoCommon/AVIDump.cpp
index c0e69fc6ab..15ffab639a 100644
--- a/Source/Core/VideoCommon/AVIDump.cpp
+++ b/Source/Core/VideoCommon/AVIDump.cpp
@@ -328,6 +328,10 @@ void AVIDump::AddFrame(const u8* data, int width, int height)
height, s_scaled_frame->data, s_scaled_frame->linesize);
}
+ s_scaled_frame->format = s_stream->codec->pix_fmt;
+ s_scaled_frame->width = s_width;
+ s_scaled_frame->height = s_height;
+
// Encode and write the image.
AVPacket pkt;
PreparePacket(&pkt);