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
diff options
context:
space:
mode:
authorPhilipp Oeser <info@graphics-engineer.com>2020-05-20 15:08:48 +0300
committerPhilipp Oeser <info@graphics-engineer.com>2020-05-22 18:41:27 +0300
commit98689f51c01141da83fb3e592dd4f4cdc75750d4 (patch)
treec3bd5dea353c7bf4e30fa2649e7d61217b99f714 /source/blender/blenkernel/intern/writeffmpeg.c
parenta76e804309421a2a95db94b85d21c2aaade982c4 (diff)
Fix T74443: No render in VP9 lossless mode
We define Lossless as CRF 0 (which is usually the best quality and is working fine with other codecs afaict), but since WebM only allows for CRF values between 2-32 and actually has a dedicated "lossless" mode, I suggest using that (it produces large files though, so double-checking would be welcome). https://trac.ffmpeg.org/wiki/Encode/VP9#LosslessVP9 Maniphest Tasks: T74443 Differential Revision: https://developer.blender.org/D7800
Diffstat (limited to 'source/blender/blenkernel/intern/writeffmpeg.c')
-rw-r--r--source/blender/blenkernel/intern/writeffmpeg.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/source/blender/blenkernel/intern/writeffmpeg.c b/source/blender/blenkernel/intern/writeffmpeg.c
index 16e56200131..724c4ab93b2 100644
--- a/source/blender/blenkernel/intern/writeffmpeg.c
+++ b/source/blender/blenkernel/intern/writeffmpeg.c
@@ -606,7 +606,10 @@ static AVStream *alloc_video_stream(FFMpegContext *context,
c->gop_size = context->ffmpeg_gop_size;
c->max_b_frames = context->ffmpeg_max_b_frames;
- if (context->ffmpeg_crf >= 0) {
+ if (context->ffmpeg_type == FFMPEG_WEBM && context->ffmpeg_crf == 0) {
+ ffmpeg_dict_set_int(&opts, "lossless", 1);
+ }
+ else if (context->ffmpeg_crf >= 0) {
ffmpeg_dict_set_int(&opts, "crf", context->ffmpeg_crf);
}
else {