Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
Derek Buitenhuis authored on 2016/01/29 02:19:06... | ... |
@@ -136,9 +136,15 @@ int ff_frame_thread_encoder_init(AVCodecContext *avctx, AVDictionary *options){ |
136 | 136 |
if (avctx->codec_id == AV_CODEC_ID_HUFFYUV || |
137 | 137 |
avctx->codec_id == AV_CODEC_ID_FFVHUFF) { |
138 | 138 |
int warn = 0; |
139 |
+ int context_model = 0; |
|
140 |
+ AVDictionaryEntry *con = av_dict_get(options, "context", NULL, AV_DICT_MATCH_CASE); |
|
141 |
+ |
|
142 |
+ if (con && con->value) |
|
143 |
+ context_model = atoi(con->value); |
|
144 |
+ |
|
139 | 145 |
if (avctx->flags & AV_CODEC_FLAG_PASS1) |
140 | 146 |
warn = 1; |
141 |
- else if(avctx->context_model > 0) { |
|
147 |
+ else if(context_model > 0) { |
|
142 | 148 |
AVDictionaryEntry *t = av_dict_get(options, "non_deterministic", |
143 | 149 |
NULL, AV_DICT_MATCH_CASE); |
144 | 150 |
warn = !t || !t->value || !atoi(t->value) ? 1 : 0; |