mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-11-26 19:01:44 +02:00
j2kdec: move s->avctx initialization to j2kdec_init()
Signed-off-by: Paul B Mahol <onemda@gmail.com>
This commit is contained in:
parent
29e9f83192
commit
be32145e9d
@ -1021,7 +1021,6 @@ static int decode_frame(AVCodecContext *avctx,
|
||||
AVFrame *picture = data;
|
||||
int tileno, ret;
|
||||
|
||||
s->avctx = avctx;
|
||||
bytestream2_init(&s->g, avpkt->data, avpkt->size);
|
||||
s->curtileno = -1;
|
||||
|
||||
@ -1072,6 +1071,7 @@ static av_cold int j2kdec_init(AVCodecContext *avctx)
|
||||
{
|
||||
J2kDecoderContext *s = avctx->priv_data;
|
||||
|
||||
s->avctx = avctx;
|
||||
avcodec_get_frame_defaults((AVFrame*)&s->picture);
|
||||
avctx->coded_frame = (AVFrame*)&s->picture;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user