]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/pgxdec.c
avcodec: Constify AVCodecs
[ffmpeg] / libavcodec / pgxdec.c
index 5c735894ab1870543ebc186cfca07016e5ecb433..1d659e82c2c8f883487436463db454223d49918a 100644 (file)
@@ -95,7 +95,7 @@ error:
 }
 
 #define WRITE_FRAME(D, PIXEL, suffix)                                                       \
-    static inline void write_frame_ ##D(AVPacket *avpkt, AVFrame *frame, GetByteContext *g, \
+    static inline void write_frame_ ##D(AVFrame *frame, GetByteContext *g, \
                                         int width, int height, int sign, int depth)         \
     {                                                                                       \
         int i, j;                                                                           \
@@ -151,14 +151,14 @@ static int pgx_decode_frame(AVCodecContext *avctx, void *data,
     p->key_frame = 1;
     avctx->bits_per_raw_sample = depth;
     if (bpp == 8)
-        write_frame_8(avpkt, p, &g, width, height, sign, depth);
+        write_frame_8(p, &g, width, height, sign, depth);
     else if (bpp == 16)
-        write_frame_16(avpkt, p, &g, width, height, sign, depth);
+        write_frame_16(p, &g, width, height, sign, depth);
     *got_frame = 1;
     return 0;
 }
 
-AVCodec ff_pgx_decoder = {
+const AVCodec ff_pgx_decoder = {
     .name           = "pgx",
     .long_name      = NULL_IF_CONFIG_SMALL("PGX (JPEG2000 Test Format)"),
     .type           = AVMEDIA_TYPE_VIDEO,