diff options
author | Andreas Rheinhardt <andreas.rheinhardt@outlook.com> | 2023-09-28 21:30:05 +0200 |
---|---|---|
committer | Andreas Rheinhardt <andreas.rheinhardt@outlook.com> | 2023-10-01 01:02:53 +0200 |
commit | 08dd036b9fc79f79cbe64245b06db903428b3bde (patch) | |
tree | 9bc539759753f8469668f4a2393dc240a8a8d323 /libavcodec/roqvideodec.c | |
parent | 7d1401ed02040f6b4ecc429c3b21c96ec86890e9 (diff) |
avcodec/roqvideo: Use void*, not AVCodecContext* for logctx
Also stop setting the field once per encode-frame.
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Diffstat (limited to 'libavcodec/roqvideodec.c')
-rw-r--r-- | libavcodec/roqvideodec.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/libavcodec/roqvideodec.c b/libavcodec/roqvideodec.c index 6f2e48d2f3..bfc69a65c9 100644 --- a/libavcodec/roqvideodec.c +++ b/libavcodec/roqvideodec.c @@ -72,7 +72,7 @@ static void roqvideo_decode_frame(RoqContext *ri, GetByteContext *gb) xpos = ypos = 0; if (chunk_size > bytestream2_get_bytes_left(gb)) { - av_log(ri->avctx, AV_LOG_ERROR, "Chunk does not fit in input buffer\n"); + av_log(ri->logctx, AV_LOG_ERROR, "Chunk does not fit in input buffer\n"); chunk_size = bytestream2_get_bytes_left(gb); } @@ -80,7 +80,7 @@ static void roqvideo_decode_frame(RoqContext *ri, GetByteContext *gb) for (yp = ypos; yp < ypos + 16; yp += 8) for (xp = xpos; xp < xpos + 16; xp += 8) { if (bytestream2_tell(gb) >= chunk_start + chunk_size) { - av_log(ri->avctx, AV_LOG_VERBOSE, "Chunk is too short\n"); + av_log(ri->logctx, AV_LOG_VERBOSE, "Chunk is too short\n"); return; } if (vqflg_pos < 0) { @@ -114,7 +114,7 @@ static void roqvideo_decode_frame(RoqContext *ri, GetByteContext *gb) if(k & 0x02) y += 4; if (bytestream2_tell(gb) >= chunk_start + chunk_size) { - av_log(ri->avctx, AV_LOG_VERBOSE, "Chunk is too short\n"); + av_log(ri->logctx, AV_LOG_VERBOSE, "Chunk is too short\n"); return; } if (vqflg_pos < 0) { @@ -169,7 +169,7 @@ static av_cold int roq_decode_init(AVCodecContext *avctx) { RoqContext *s = avctx->priv_data; - s->avctx = avctx; + s->logctx = avctx; if (avctx->width % 16 || avctx->height % 16) { avpriv_request_sample(avctx, "Dimensions not being a multiple of 16"); |