...
|
...
|
@@ -216,9 +216,10 @@ static int tgq_decode_frame(AVCodecContext *avctx,
|
216
|
216
|
s->height = bytestream2_get_le16u(&s->gb);
|
217
|
217
|
}
|
218
|
218
|
|
219
|
|
- if (s->avctx->width!=s->width || s->avctx->height!=s->height) {
|
220
|
|
- avcodec_set_dimensions(s->avctx, s->width, s->height);
|
221
|
|
- }
|
|
219
|
+ ret = ff_set_dimensions(s->avctx, s->width, s->height);
|
|
220
|
+ if (ret < 0)
|
|
221
|
+ return ret;
|
|
222
|
+
|
222
|
223
|
tgq_calculate_qtable(s, bytestream2_get_byteu(&s->gb));
|
223
|
224
|
bytestream2_skip(&s->gb, 3);
|
224
|
225
|
|