Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/source
diff options
context:
space:
mode:
authorXavier Thomas <xavier.thomas.1980@gmail.com>2010-05-04 04:28:41 +0400
committerXavier Thomas <xavier.thomas.1980@gmail.com>2010-05-04 04:28:41 +0400
commit850a4b508bcf3db4c010bd1395671b26a8a51d29 (patch)
tree5f46268c12a66d5bcaa79291e9a913dd7809e4c5 /source
parent44c0f38e6ceb6d7b2a07aa23b2c0811a609d17d5 (diff)
Fix [#21353] Rendering h264 reports broken settings and fail.
Also silenced a warning.
Diffstat (limited to 'source')
-rw-r--r--source/blender/blenkernel/intern/writeffmpeg.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/source/blender/blenkernel/intern/writeffmpeg.c b/source/blender/blenkernel/intern/writeffmpeg.c
index 57d6c91c3dd..8ebf98ef930 100644
--- a/source/blender/blenkernel/intern/writeffmpeg.c
+++ b/source/blender/blenkernel/intern/writeffmpeg.c
@@ -362,7 +362,7 @@ static AVFrame* generate_video_frame(uint8_t* pixels, ReportList *reports)
}
if (c->pix_fmt != PIX_FMT_BGR32) {
- sws_scale(img_convert_ctx, rgb_frame->data,
+ sws_scale(img_convert_ctx, (const uint8_t * const*) rgb_frame->data,
rgb_frame->linesize, 0, c->height,
current_frame->data, current_frame->linesize);
delete_picture(rgb_frame);
@@ -516,6 +516,12 @@ static AVStream* alloc_video_stream(RenderData *rd, int codec_id, AVFormatContex
/* arghhhh ... */
c->pix_fmt = PIX_FMT_YUV420P;
}
+
+ if (codec_id == CODEC_ID_H264) {
+ /* correct wrong default ffmpeg param which crash x264 */
+ c->qmin=10;
+ c->qmax=51;
+ }
if ((of->oformat->flags & AVFMT_GLOBALHEADER)
// || !strcmp(of->oformat->name, "mp4")