[FFmpeg-cvslog] avcodec/internal: Move ff_set_dimensions() to decode.h

Andreas Rheinhardt git at videolan.org
Sun Aug 28 13:27:06 EEST 2022


ffmpeg | branch: master | Andreas Rheinhardt <andreas.rheinhardt at outlook.com> | Wed Aug 24 22:03:27 2022 +0200| [b9eaf77ed1b3b551f71f90b3fb2624379d0b29c3] | committer: Andreas Rheinhardt

avcodec/internal: Move ff_set_dimensions() to decode.h

Decoder-only, as the dimensions are set by the user when encoding.

Also fixup the other headers a bit while removing unnecessary internal.h
inclusions.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at outlook.com>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=b9eaf77ed1b3b551f71f90b3fb2624379d0b29c3
---

 libavcodec/agm.c                  | 3 ---
 libavcodec/aliaspixdec.c          | 1 -
 libavcodec/ansi.c                 | 2 --
 libavcodec/av1dec.c               | 1 -
 libavcodec/avs.c                  | 1 -
 libavcodec/bmp.c                  | 1 -
 libavcodec/brenderpix.c           | 1 -
 libavcodec/c93.c                  | 1 -
 libavcodec/cavsdec.c              | 1 -
 libavcodec/cdgraphics.c           | 1 -
 libavcodec/cdxl.c                 | 2 --
 libavcodec/cfhd.c                 | 4 ++--
 libavcodec/clearvideo.c           | 1 -
 libavcodec/cri.c                  | 2 +-
 libavcodec/dds.c                  | 2 --
 libavcodec/decode.h               | 6 ++++++
 libavcodec/diracdec.c             | 3 ---
 libavcodec/dnxhddec.c             | 4 ++--
 libavcodec/dpx.c                  | 2 --
 libavcodec/dvbsubdec.c            | 2 +-
 libavcodec/dvdec.c                | 3 ---
 libavcodec/dvdsubdec.c            | 2 +-
 libavcodec/eacmv.c                | 1 -
 libavcodec/eamad.c                | 1 -
 libavcodec/eatgq.c                | 1 -
 libavcodec/eatgv.c                | 2 --
 libavcodec/eatqi.c                | 1 -
 libavcodec/exr.c                  | 1 -
 libavcodec/fitsdec.c              | 1 -
 libavcodec/flashsv.c              | 4 +---
 libavcodec/g2meet.c               | 3 ---
 libavcodec/gemdec.c               | 1 -
 libavcodec/gifdec.c               | 2 --
 libavcodec/h261dec.c              | 2 +-
 libavcodec/h263dec.c              | 1 -
 libavcodec/hdrdec.c               | 5 +----
 libavcodec/hq_hqa.c               | 2 --
 libavcodec/imm4.c                 | 4 +---
 libavcodec/indeo3.c               | 1 -
 libavcodec/internal.h             | 6 ------
 libavcodec/ivi.c                  | 1 -
 libavcodec/jpeg2000dec.c          | 2 +-
 libavcodec/kgv1dec.c              | 1 -
 libavcodec/libaomdec.c            | 1 -
 libavcodec/libjxldec.c            | 1 -
 libavcodec/libopenh264dec.c       | 1 -
 libavcodec/libopenjpegdec.c       | 2 +-
 libavcodec/librsvgdec.c           | 1 -
 libavcodec/libuavs3d.c            | 1 -
 libavcodec/libvpxdec.c            | 1 -
 libavcodec/magicyuv.c             | 3 +--
 libavcodec/mediacodecdec_common.c | 1 -
 libavcodec/mimic.c                | 4 +---
 libavcodec/mpeg4video_parser.c    | 2 +-
 libavcodec/mpegvideo_parser.c     | 2 +-
 libavcodec/mvcdec.c               | 1 -
 libavcodec/notchlc.c              | 4 +---
 libavcodec/nuv.c                  | 6 +-----
 libavcodec/pcx.c                  | 2 --
 libavcodec/pgssubdec.c            | 3 +--
 libavcodec/pgxdec.c               | 1 -
 libavcodec/photocd.c              | 2 +-
 libavcodec/pictordec.c            | 1 -
 libavcodec/pixlet.c               | 4 +---
 libavcodec/pngdec.c               | 2 +-
 libavcodec/pnm.c                  | 2 +-
 libavcodec/proresdec2.c           | 3 +--
 libavcodec/psd.c                  | 1 -
 libavcodec/ptx.c                  | 1 -
 libavcodec/qdrw.c                 | 1 -
 libavcodec/qoidec.c               | 5 +----
 libavcodec/rasc.c                 | 1 -
 libavcodec/rl2.c                  | 3 ---
 libavcodec/rv10.c                 | 2 +-
 libavcodec/rv34.c                 | 3 +--
 libavcodec/sanm.c                 | 3 ---
 libavcodec/sga.c                  | 1 -
 libavcodec/sgidec.c               | 2 --
 libavcodec/sunrast.c              | 2 --
 libavcodec/svq1dec.c              | 1 -
 libavcodec/svq3.c                 | 3 ---
 libavcodec/targa.c                | 3 ---
 libavcodec/tdsc.c                 | 1 -
 libavcodec/tiertexseqv.c          | 1 -
 libavcodec/tiff.c                 | 5 +----
 libavcodec/truemotion1.c          | 1 -
 libavcodec/truemotion2rt.c        | 6 ------
 libavcodec/txd.c                  | 3 ---
 libavcodec/v4l2_context.c         | 2 +-
 libavcodec/vbndec.c               | 1 -
 libavcodec/vc1.c                  | 1 -
 libavcodec/vp3.c                  | 4 +---
 libavcodec/vp5.c                  | 3 +--
 libavcodec/vp56.c                 | 1 -
 libavcodec/vp6.c                  | 2 +-
 libavcodec/vp8.c                  | 3 ---
 libavcodec/vp9.c                  | 2 +-
 libavcodec/vqavideo.c             | 3 ---
 libavcodec/wbmpdec.c              | 2 +-
 libavcodec/webp.c                 | 2 +-
 libavcodec/xbmdec.c               | 3 ---
 libavcodec/xpmdec.c               | 1 -
 libavcodec/xwddec.c               | 1 -
 103 files changed, 42 insertions(+), 178 deletions(-)

diff --git a/libavcodec/agm.c b/libavcodec/agm.c
index 08a5f05b91..38d9c67f80 100644
--- a/libavcodec/agm.c
+++ b/libavcodec/agm.c
@@ -20,8 +20,6 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
-#include <stdio.h>
-#include <stdlib.h>
 #include <string.h>
 
 #define BITSTREAM_READER_LE
@@ -35,7 +33,6 @@
 #include "decode.h"
 #include "get_bits.h"
 #include "idctdsp.h"
-#include "internal.h"
 
 static const uint8_t unscaled_luma[64] = {
     16, 11, 10, 16, 24, 40, 51, 61, 12, 12, 14, 19,
diff --git a/libavcodec/aliaspixdec.c b/libavcodec/aliaspixdec.c
index 522b894af5..7dedfe3aa1 100644
--- a/libavcodec/aliaspixdec.c
+++ b/libavcodec/aliaspixdec.c
@@ -25,7 +25,6 @@
 #include "bytestream.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 
 #define ALIAS_HEADER_SIZE 10
 
diff --git a/libavcodec/ansi.c b/libavcodec/ansi.c
index 1cd9ebceba..89bde59b40 100644
--- a/libavcodec/ansi.c
+++ b/libavcodec/ansi.c
@@ -26,13 +26,11 @@
 
 #include "libavutil/common.h"
 #include "libavutil/frame.h"
-#include "libavutil/lfg.h"
 #include "libavutil/xga_font_data.h"
 #include "avcodec.h"
 #include "cga_data.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 
 #define ATTR_BOLD         0x01  /**< Bold/Bright-foreground (mode 1) */
 #define ATTR_FAINT        0x02  /**< Faint (mode 2) */
diff --git a/libavcodec/av1dec.c b/libavcodec/av1dec.c
index 7b5b2c996a..401462701f 100644
--- a/libavcodec/av1dec.c
+++ b/libavcodec/av1dec.c
@@ -29,7 +29,6 @@
 #include "codec_internal.h"
 #include "decode.h"
 #include "hwconfig.h"
-#include "internal.h"
 #include "profiles.h"
 #include "thread.h"
 
diff --git a/libavcodec/avs.c b/libavcodec/avs.c
index 86a41a31be..ca2b2d4701 100644
--- a/libavcodec/avs.c
+++ b/libavcodec/avs.c
@@ -23,7 +23,6 @@
 #include "codec_internal.h"
 #include "decode.h"
 #include "get_bits.h"
-#include "internal.h"
 
 typedef struct AvsContext {
     AVFrame *frame;
diff --git a/libavcodec/bmp.c b/libavcodec/bmp.c
index 7bbaabcda4..d381eb2eee 100644
--- a/libavcodec/bmp.c
+++ b/libavcodec/bmp.c
@@ -26,7 +26,6 @@
 #include "bmp.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 #include "msrledec.h"
 
 static int bmp_decode_frame(AVCodecContext *avctx, AVFrame *p,
diff --git a/libavcodec/brenderpix.c b/libavcodec/brenderpix.c
index 2d8e978c1e..170acc39a3 100644
--- a/libavcodec/brenderpix.c
+++ b/libavcodec/brenderpix.c
@@ -27,7 +27,6 @@
 #include "bytestream.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 
 #define HEADER1_CHUNK    0x03
 #define HEADER2_CHUNK    0x3D
diff --git a/libavcodec/c93.c b/libavcodec/c93.c
index 871ae589e6..03381f1e88 100644
--- a/libavcodec/c93.c
+++ b/libavcodec/c93.c
@@ -23,7 +23,6 @@
 #include "bytestream.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 
 typedef struct C93DecoderContext {
     AVFrame *pictures[2];
diff --git a/libavcodec/cavsdec.c b/libavcodec/cavsdec.c
index 417c73bd2e..3d4e306c93 100644
--- a/libavcodec/cavsdec.c
+++ b/libavcodec/cavsdec.c
@@ -32,7 +32,6 @@
 #include "cavs.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 #include "mathops.h"
 #include "mpeg12data.h"
 #include "startcode.h"
diff --git a/libavcodec/cdgraphics.c b/libavcodec/cdgraphics.c
index 240c57d5f8..19366bdcfe 100644
--- a/libavcodec/cdgraphics.c
+++ b/libavcodec/cdgraphics.c
@@ -23,7 +23,6 @@
 #include "bytestream.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 
 /**
  * @file
diff --git a/libavcodec/cdxl.c b/libavcodec/cdxl.c
index 64fcdffba4..5821aaeb22 100644
--- a/libavcodec/cdxl.c
+++ b/libavcodec/cdxl.c
@@ -28,13 +28,11 @@
 #define UNCHECKED_BITSTREAM_READER 1
 
 #include "libavutil/intreadwrite.h"
-#include "libavutil/imgutils.h"
 #include "avcodec.h"
 #include "bytestream.h"
 #include "codec_internal.h"
 #include "decode.h"
 #include "get_bits.h"
-#include "internal.h"
 
 #define BIT_PLANAR   0x00
 #define CHUNKY       0x20
diff --git a/libavcodec/cfhd.c b/libavcodec/cfhd.c
index 9f218f6384..f908aaf8fb 100644
--- a/libavcodec/cfhd.c
+++ b/libavcodec/cfhd.c
@@ -26,13 +26,13 @@
 #include "libavutil/attributes.h"
 #include "libavutil/buffer.h"
 #include "libavutil/common.h"
-#include "libavutil/imgutils.h"
 #include "libavutil/intreadwrite.h"
-#include "libavutil/opt.h"
+#include "libavutil/pixdesc.h"
 
 #include "avcodec.h"
 #include "bytestream.h"
 #include "codec_internal.h"
+#include "decode.h"
 #include "get_bits.h"
 #include "internal.h"
 #include "thread.h"
diff --git a/libavcodec/clearvideo.c b/libavcodec/clearvideo.c
index 4e5fc02e23..8615bf2a51 100644
--- a/libavcodec/clearvideo.c
+++ b/libavcodec/clearvideo.c
@@ -33,7 +33,6 @@
 #include "decode.h"
 #include "get_bits.h"
 #include "idctdsp.h"
-#include "internal.h"
 #include "mathops.h"
 #include "clearvideodata.h"
 
diff --git a/libavcodec/cri.c b/libavcodec/cri.c
index 2ac04575b7..65eb53d22e 100644
--- a/libavcodec/cri.c
+++ b/libavcodec/cri.c
@@ -32,8 +32,8 @@
 #include "avcodec.h"
 #include "bytestream.h"
 #include "codec_internal.h"
+#include "decode.h"
 #include "get_bits.h"
-#include "internal.h"
 #include "thread.h"
 
 typedef struct CRIContext {
diff --git a/libavcodec/dds.c b/libavcodec/dds.c
index 63f63efca2..6904191310 100644
--- a/libavcodec/dds.c
+++ b/libavcodec/dds.c
@@ -35,9 +35,7 @@
 #include "bytestream.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 #include "texturedsp.h"
-#include "thread.h"
 
 #define DDPF_FOURCC    (1 <<  2)
 #define DDPF_PALETTE   (1 <<  5)
diff --git a/libavcodec/decode.h b/libavcodec/decode.h
index b82d953516..d40327d5ab 100644
--- a/libavcodec/decode.h
+++ b/libavcodec/decode.h
@@ -99,6 +99,12 @@ int ff_copy_palette(void *dst, const AVPacket *src, void *logctx);
  */
 int ff_decode_preinit(AVCodecContext *avctx);
 
+/**
+ * Check that the provided frame dimensions are valid and set them on the codec
+ * context.
+ */
+int ff_set_dimensions(AVCodecContext *s, int width, int height);
+
 /**
  * Check that the provided sample aspect ratio is valid and set it on the codec
  * context.
diff --git a/libavcodec/diracdec.c b/libavcodec/diracdec.c
index 59c5e81904..ef00c29150 100644
--- a/libavcodec/diracdec.c
+++ b/libavcodec/diracdec.c
@@ -31,14 +31,11 @@
 #include "libavutil/thread.h"
 #include "avcodec.h"
 #include "get_bits.h"
-#include "bytestream.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 #include "golomb.h"
 #include "dirac_arith.h"
 #include "dirac_vlc.h"
-#include "mpeg12data.h"
 #include "mpegpicture.h"
 #include "mpegvideoencdsp.h"
 #include "dirac_dwt.h"
diff --git a/libavcodec/dnxhddec.c b/libavcodec/dnxhddec.c
index 8b6c473c5b..1c749d026c 100644
--- a/libavcodec/dnxhddec.c
+++ b/libavcodec/dnxhddec.c
@@ -24,17 +24,17 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
-#include "libavutil/imgutils.h"
 #include "libavutil/mem_internal.h"
+#include "libavutil/pixdesc.h"
 
 #include "avcodec.h"
 #include "blockdsp.h"
 #include "codec_internal.h"
+#include "decode.h"
 #define  UNCHECKED_BITSTREAM_READER 1
 #include "get_bits.h"
 #include "dnxhddata.h"
 #include "idctdsp.h"
-#include "internal.h"
 #include "profiles.h"
 #include "thread.h"
 
diff --git a/libavcodec/dpx.c b/libavcodec/dpx.c
index c3f0d3f95a..afd9f17b04 100644
--- a/libavcodec/dpx.c
+++ b/libavcodec/dpx.c
@@ -24,11 +24,9 @@
 #include "libavutil/intfloat.h"
 #include "libavutil/imgutils.h"
 #include "libavutil/timecode.h"
-#include "bytestream.h"
 #include "avcodec.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 
 enum DPX_TRC {
     DPX_TRC_USER_DEFINED       = 0,
diff --git a/libavcodec/dvbsubdec.c b/libavcodec/dvbsubdec.c
index 90c062502b..63d4a13bcb 100644
--- a/libavcodec/dvbsubdec.c
+++ b/libavcodec/dvbsubdec.c
@@ -23,7 +23,7 @@
 #include "get_bits.h"
 #include "bytestream.h"
 #include "codec_internal.h"
-#include "internal.h"
+#include "decode.h"
 #include "libavutil/colorspace.h"
 #include "libavutil/imgutils.h"
 #include "libavutil/opt.h"
diff --git a/libavcodec/dvdec.c b/libavcodec/dvdec.c
index d1de9cd9e2..12e837c9ff 100644
--- a/libavcodec/dvdec.c
+++ b/libavcodec/dvdec.c
@@ -36,10 +36,8 @@
  */
 
 #include "libavutil/avassert.h"
-#include "libavutil/imgutils.h"
 #include "libavutil/internal.h"
 #include "libavutil/mem_internal.h"
-#include "libavutil/pixdesc.h"
 #include "libavutil/thread.h"
 
 #include "avcodec.h"
@@ -49,7 +47,6 @@
 #include "dv_profile_internal.h"
 #include "dvdata.h"
 #include "get_bits.h"
-#include "internal.h"
 #include "put_bits.h"
 #include "simple_idct.h"
 #include "thread.h"
diff --git a/libavcodec/dvdsubdec.c b/libavcodec/dvdsubdec.c
index 7fa3363a9c..4b692c093f 100644
--- a/libavcodec/dvdsubdec.c
+++ b/libavcodec/dvdsubdec.c
@@ -21,13 +21,13 @@
 
 #include "avcodec.h"
 #include "codec_internal.h"
+#include "decode.h"
 #include "get_bits.h"
 #include "internal.h"
 
 #include "libavutil/attributes.h"
 #include "libavutil/colorspace.h"
 #include "libavutil/opt.h"
-#include "libavutil/imgutils.h"
 #include "libavutil/bswap.h"
 
 typedef struct DVDSubContext
diff --git a/libavcodec/eacmv.c b/libavcodec/eacmv.c
index 733cc2a1c0..e8d757ed37 100644
--- a/libavcodec/eacmv.c
+++ b/libavcodec/eacmv.c
@@ -34,7 +34,6 @@
 #include "avcodec.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 
 typedef struct CmvContext {
     AVCodecContext *avctx;
diff --git a/libavcodec/eamad.c b/libavcodec/eamad.c
index 70cea0ed6c..4904730c65 100644
--- a/libavcodec/eamad.c
+++ b/libavcodec/eamad.c
@@ -40,7 +40,6 @@
 #include "aandcttab.h"
 #include "eaidct.h"
 #include "idctdsp.h"
-#include "internal.h"
 #include "mpeg12data.h"
 #include "mpeg12vlc.h"
 
diff --git a/libavcodec/eatgq.c b/libavcodec/eatgq.c
index 5d57fb34f8..bdf70292fd 100644
--- a/libavcodec/eatgq.c
+++ b/libavcodec/eatgq.c
@@ -40,7 +40,6 @@
 #include "eaidct.h"
 #include "get_bits.h"
 #include "idctdsp.h"
-#include "internal.h"
 
 typedef struct TgqContext {
     AVCodecContext *avctx;
diff --git a/libavcodec/eatgv.c b/libavcodec/eatgv.c
index b1483cc586..02a547b2da 100644
--- a/libavcodec/eatgv.c
+++ b/libavcodec/eatgv.c
@@ -28,7 +28,6 @@
  * http://wiki.multimedia.cx/index.php?title=Electronic_Arts_TGV
  */
 
-#include "libavutil/imgutils.h"
 #include "libavutil/mem.h"
 
 #define BITSTREAM_READER_LE
@@ -36,7 +35,6 @@
 #include "get_bits.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 
 #define EA_PREAMBLE_SIZE    8
 #define kVGT_TAG MKTAG('k', 'V', 'G', 'T')
diff --git a/libavcodec/eatqi.c b/libavcodec/eatqi.c
index 013e5415d2..1aafd9af0c 100644
--- a/libavcodec/eatqi.c
+++ b/libavcodec/eatqi.c
@@ -37,7 +37,6 @@
 #include "aandcttab.h"
 #include "eaidct.h"
 #include "idctdsp.h"
-#include "internal.h"
 #include "mpeg12data.h"
 #include "mpeg12dec.h"
 
diff --git a/libavcodec/exr.c b/libavcodec/exr.c
index a62cc95d28..f6eab048f4 100644
--- a/libavcodec/exr.c
+++ b/libavcodec/exr.c
@@ -54,7 +54,6 @@
 #include "decode.h"
 #include "exrdsp.h"
 #include "get_bits.h"
-#include "internal.h"
 #include "mathops.h"
 #include "thread.h"
 
diff --git a/libavcodec/fitsdec.c b/libavcodec/fitsdec.c
index 28954f370c..7e45f2a65f 100644
--- a/libavcodec/fitsdec.c
+++ b/libavcodec/fitsdec.c
@@ -33,7 +33,6 @@
 #include "avcodec.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 #include <float.h>
 #include "libavutil/intreadwrite.h"
 #include "libavutil/intfloat.h"
diff --git a/libavcodec/flashsv.c b/libavcodec/flashsv.c
index 11d6657394..76459df4cb 100644
--- a/libavcodec/flashsv.c
+++ b/libavcodec/flashsv.c
@@ -35,8 +35,7 @@
 
 #include "config_components.h"
 
-#include <stdio.h>
-#include <stdlib.h>
+#include <stddef.h>
 #include <zlib.h>
 
 #include "libavutil/intreadwrite.h"
@@ -45,7 +44,6 @@
 #include "codec_internal.h"
 #include "decode.h"
 #include "get_bits.h"
-#include "internal.h"
 #include "zlib_wrapper.h"
 
 typedef struct BlockInfo {
diff --git a/libavcodec/g2meet.c b/libavcodec/g2meet.c
index f2300e1ca6..154ff10aad 100644
--- a/libavcodec/g2meet.c
+++ b/libavcodec/g2meet.c
@@ -29,7 +29,6 @@
 #include <zlib.h>
 
 #include "libavutil/imgutils.h"
-#include "libavutil/intreadwrite.h"
 #include "libavutil/mem_internal.h"
 
 #include "avcodec.h"
@@ -40,9 +39,7 @@
 #include "elsdec.h"
 #include "get_bits.h"
 #include "idctdsp.h"
-#include "internal.h"
 #include "jpegtables.h"
-#include "mjpeg.h"
 #include "mjpegdec.h"
 
 #define EPIC_PIX_STACK_SIZE 1024
diff --git a/libavcodec/gemdec.c b/libavcodec/gemdec.c
index 39bfedb560..5533f981dc 100644
--- a/libavcodec/gemdec.c
+++ b/libavcodec/gemdec.c
@@ -28,7 +28,6 @@
 #include "bytestream.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 
 static const uint32_t gem_color_palette[16]={
     0xFFFFFFFF, 0xFFFF0000, 0xFF00FF00, 0xFFFFFF00,
diff --git a/libavcodec/gifdec.c b/libavcodec/gifdec.c
index 15d4f9743f..d8638a37be 100644
--- a/libavcodec/gifdec.c
+++ b/libavcodec/gifdec.c
@@ -21,13 +21,11 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
-#include "libavutil/imgutils.h"
 #include "libavutil/opt.h"
 #include "avcodec.h"
 #include "bytestream.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 #include "lzw.h"
 #include "gif.h"
 
diff --git a/libavcodec/h261dec.c b/libavcodec/h261dec.c
index 97c126ab5a..70a26f443d 100644
--- a/libavcodec/h261dec.c
+++ b/libavcodec/h261dec.c
@@ -29,12 +29,12 @@
 #include "libavutil/thread.h"
 #include "avcodec.h"
 #include "codec_internal.h"
+#include "decode.h"
 #include "mpeg_er.h"
 #include "mpegutils.h"
 #include "mpegvideo.h"
 #include "mpegvideodec.h"
 #include "h261.h"
-#include "internal.h"
 
 #define H261_MBA_VLC_BITS 8
 #define H261_MTYPE_VLC_BITS 6
diff --git a/libavcodec/h263dec.c b/libavcodec/h263dec.c
index 87fbf87c8a..8b4101272a 100644
--- a/libavcodec/h263dec.c
+++ b/libavcodec/h263dec.c
@@ -40,7 +40,6 @@
 #include "h263_parser.h"
 #endif
 #include "hwconfig.h"
-#include "internal.h"
 #include "mpeg_er.h"
 #include "mpeg4video.h"
 #include "mpeg4videodec.h"
diff --git a/libavcodec/hdrdec.c b/libavcodec/hdrdec.c
index 29e87057fa..9079e4a843 100644
--- a/libavcodec/hdrdec.c
+++ b/libavcodec/hdrdec.c
@@ -18,13 +18,10 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
-#include <stdlib.h>
-
-#include "libavutil/imgutils.h"
 #include "avcodec.h"
-#include "internal.h"
 #include "bytestream.h"
 #include "codec_internal.h"
+#include "decode.h"
 #include "thread.h"
 
 #define MINELEN 8
diff --git a/libavcodec/hq_hqa.c b/libavcodec/hq_hqa.c
index e0fbf7de65..075c74d105 100644
--- a/libavcodec/hq_hqa.c
+++ b/libavcodec/hq_hqa.c
@@ -21,7 +21,6 @@
 #include <stdint.h>
 
 #include "libavutil/attributes.h"
-#include "libavutil/intreadwrite.h"
 
 #include "avcodec.h"
 #include "bytestream.h"
@@ -29,7 +28,6 @@
 #include "codec_internal.h"
 #include "decode.h"
 #include "get_bits.h"
-#include "internal.h"
 
 #include "hq_hqa.h"
 #include "hq_hqadsp.h"
diff --git a/libavcodec/imm4.c b/libavcodec/imm4.c
index b2840a2c3f..96a395a100 100644
--- a/libavcodec/imm4.c
+++ b/libavcodec/imm4.c
@@ -20,8 +20,7 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
-#include <stdio.h>
-#include <stdlib.h>
+#include <stddef.h>
 #include <string.h>
 
 #include "libavutil/mem_internal.h"
@@ -34,7 +33,6 @@
 #include "copy_block.h"
 #include "get_bits.h"
 #include "idctdsp.h"
-#include "internal.h"
 
 #define CBPLO_VLC_BITS   6
 #define CBPHI_VLC_BITS   6
diff --git a/libavcodec/indeo3.c b/libavcodec/indeo3.c
index 95708f3636..a41608bb7e 100644
--- a/libavcodec/indeo3.c
+++ b/libavcodec/indeo3.c
@@ -39,7 +39,6 @@
 #include "bytestream.h"
 #include "get_bits.h"
 #include "hpeldsp.h"
-#include "internal.h"
 
 #include "indeo3data.h"
 
diff --git a/libavcodec/internal.h b/libavcodec/internal.h
index 0c1225f98b..823067b7ee 100644
--- a/libavcodec/internal.h
+++ b/libavcodec/internal.h
@@ -216,12 +216,6 @@ int avpriv_h264_has_num_reorder_frames(AVCodecContext *avctx);
 
 int avpriv_codec_get_cap_skip_frame_fill_param(const AVCodec *codec);
 
-/**
- * Check that the provided frame dimensions are valid and set them on the codec
- * context.
- */
-int ff_set_dimensions(AVCodecContext *s, int width, int height);
-
 /**
  * Add or update AV_FRAME_DATA_MATRIXENCODING side data.
  */
diff --git a/libavcodec/ivi.c b/libavcodec/ivi.c
index cddef6f51e..43f3cb1da3 100644
--- a/libavcodec/ivi.c
+++ b/libavcodec/ivi.c
@@ -36,7 +36,6 @@
 #include "avcodec.h"
 #include "decode.h"
 #include "get_bits.h"
-#include "internal.h"
 #include "ivi.h"
 #include "ivi_dsp.h"
 
diff --git a/libavcodec/jpeg2000dec.c b/libavcodec/jpeg2000dec.c
index 5e177cec25..2c1191035c 100644
--- a/libavcodec/jpeg2000dec.c
+++ b/libavcodec/jpeg2000dec.c
@@ -37,7 +37,7 @@
 #include "avcodec.h"
 #include "bytestream.h"
 #include "codec_internal.h"
-#include "internal.h"
+#include "decode.h"
 #include "thread.h"
 #include "jpeg2000.h"
 #include "jpeg2000dsp.h"
diff --git a/libavcodec/kgv1dec.c b/libavcodec/kgv1dec.c
index 0dfb796483..11dfc1b84f 100644
--- a/libavcodec/kgv1dec.c
+++ b/libavcodec/kgv1dec.c
@@ -30,7 +30,6 @@
 #include "avcodec.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 
 typedef struct KgvContext {
     uint16_t *frame_buffer;
diff --git a/libavcodec/libaomdec.c b/libavcodec/libaomdec.c
index 274c67baaa..5ed219b43d 100644
--- a/libavcodec/libaomdec.c
+++ b/libavcodec/libaomdec.c
@@ -33,7 +33,6 @@
 #include "avcodec.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 #include "libaom.h"
 #include "profiles.h"
 
diff --git a/libavcodec/libjxldec.c b/libavcodec/libjxldec.c
index f0c5533a8b..0d59160d27 100644
--- a/libavcodec/libjxldec.c
+++ b/libavcodec/libjxldec.c
@@ -37,7 +37,6 @@
 #include "avcodec.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 
 #include <jxl/decode.h>
 #include <jxl/thread_parallel_runner.h>
diff --git a/libavcodec/libopenh264dec.c b/libavcodec/libopenh264dec.c
index df270c77df..3a8be36bf6 100644
--- a/libavcodec/libopenh264dec.c
+++ b/libavcodec/libopenh264dec.c
@@ -32,7 +32,6 @@
 #include "avcodec.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 #include "libopenh264.h"
 
 typedef struct SVCContext {
diff --git a/libavcodec/libopenjpegdec.c b/libavcodec/libopenjpegdec.c
index fa420f145b..be2337d9b2 100644
--- a/libavcodec/libopenjpegdec.c
+++ b/libavcodec/libopenjpegdec.c
@@ -32,7 +32,7 @@
 
 #include "avcodec.h"
 #include "codec_internal.h"
-#include "internal.h"
+#include "decode.h"
 #include "thread.h"
 
 #include <openjpeg.h>
diff --git a/libavcodec/librsvgdec.c b/libavcodec/librsvgdec.c
index bfb83da614..cfafae2652 100644
--- a/libavcodec/librsvgdec.c
+++ b/libavcodec/librsvgdec.c
@@ -22,7 +22,6 @@
 #include "avcodec.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 #include "libavutil/opt.h"
 #include "librsvg-2.0/librsvg/rsvg.h"
 
diff --git a/libavcodec/libuavs3d.c b/libavcodec/libuavs3d.c
index f2649540be..95616fcacb 100644
--- a/libavcodec/libuavs3d.c
+++ b/libavcodec/libuavs3d.c
@@ -31,7 +31,6 @@
 #include "avs3.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 #include "uavs3d.h"
 
 typedef struct uavs3d_context {
diff --git a/libavcodec/libvpxdec.c b/libavcodec/libvpxdec.c
index c5b95332d3..c7cb744312 100644
--- a/libavcodec/libvpxdec.c
+++ b/libavcodec/libvpxdec.c
@@ -37,7 +37,6 @@
 #include "avcodec.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 #include "libvpx.h"
 #include "profiles.h"
 
diff --git a/libavcodec/magicyuv.c b/libavcodec/magicyuv.c
index 65dbb6a2f1..8b30ce08ac 100644
--- a/libavcodec/magicyuv.c
+++ b/libavcodec/magicyuv.c
@@ -29,9 +29,8 @@
 #include "avcodec.h"
 #include "bytestream.h"
 #include "codec_internal.h"
+#include "decode.h"
 #include "get_bits.h"
-#include "huffyuvdsp.h"
-#include "internal.h"
 #include "lossless_videodsp.h"
 #include "thread.h"
 
diff --git a/libavcodec/mediacodecdec_common.c b/libavcodec/mediacodecdec_common.c
index 7952c3c34c..9fa769656c 100644
--- a/libavcodec/mediacodecdec_common.c
+++ b/libavcodec/mediacodecdec_common.c
@@ -33,7 +33,6 @@
 
 #include "avcodec.h"
 #include "decode.h"
-#include "internal.h"
 
 #include "mediacodec.h"
 #include "mediacodec_surface.h"
diff --git a/libavcodec/mimic.c b/libavcodec/mimic.c
index bcf10b7ae1..f5164e82e7 100644
--- a/libavcodec/mimic.c
+++ b/libavcodec/mimic.c
@@ -19,8 +19,6 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
-#include <stdlib.h>
-#include <string.h>
 #include <stdint.h>
 
 #include "libavutil/mem_internal.h"
@@ -29,7 +27,7 @@
 #include "avcodec.h"
 #include "blockdsp.h"
 #include "codec_internal.h"
-#include "internal.h"
+#include "decode.h"
 #include "get_bits.h"
 #include "bytestream.h"
 #include "bswapdsp.h"
diff --git a/libavcodec/mpeg4video_parser.c b/libavcodec/mpeg4video_parser.c
index 3d0d0e4714..bbdb2209cf 100644
--- a/libavcodec/mpeg4video_parser.c
+++ b/libavcodec/mpeg4video_parser.c
@@ -22,7 +22,7 @@
 
 #define UNCHECKED_BITSTREAM_READER 1
 
-#include "internal.h"
+#include "decode.h"
 #include "parser.h"
 #include "mpegvideo.h"
 #include "mpeg4video.h"
diff --git a/libavcodec/mpegvideo_parser.c b/libavcodec/mpegvideo_parser.c
index 97da5bfe11..ac6efb6909 100644
--- a/libavcodec/mpegvideo_parser.c
+++ b/libavcodec/mpegvideo_parser.c
@@ -20,7 +20,7 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
-#include "internal.h"
+#include "decode.h"
 #include "parser.h"
 #include "mpeg12.h"
 #include "mpeg12data.h"
diff --git a/libavcodec/mvcdec.c b/libavcodec/mvcdec.c
index d2e9f4b631..0040ff0853 100644
--- a/libavcodec/mvcdec.c
+++ b/libavcodec/mvcdec.c
@@ -32,7 +32,6 @@
 #include "bytestream.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 
 typedef struct MvcContext {
     int vflip;
diff --git a/libavcodec/notchlc.c b/libavcodec/notchlc.c
index 7f2bca35f2..fce11e97f2 100644
--- a/libavcodec/notchlc.c
+++ b/libavcodec/notchlc.c
@@ -20,16 +20,14 @@
  */
 
 #include <stdio.h>
-#include <stdlib.h>
 #include <string.h>
 
 #define BITSTREAM_READER_LE
-#include "libavutil/intreadwrite.h"
 #include "avcodec.h"
 #include "bytestream.h"
 #include "codec_internal.h"
+#include "decode.h"
 #include "get_bits.h"
-#include "internal.h"
 #include "lzf.h"
 #include "thread.h"
 
diff --git a/libavcodec/nuv.c b/libavcodec/nuv.c
index c404bd8cf0..8dbfa7f726 100644
--- a/libavcodec/nuv.c
+++ b/libavcodec/nuv.c
@@ -19,11 +19,9 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
-#include <stdio.h>
-#include <stdlib.h>
+#include <stddef.h>
 #include <limits.h>
 
-#include "libavutil/bswap.h"
 #include "libavutil/common.h"
 #include "libavutil/intreadwrite.h"
 #include "libavutil/lzo.h"
@@ -31,8 +29,6 @@
 #include "avcodec.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "idctdsp.h"
-#include "internal.h"
 #include "rtjpeg.h"
 
 typedef struct NuvContext {
diff --git a/libavcodec/pcx.c b/libavcodec/pcx.c
index 7a47ef827c..3b82e5ba3e 100644
--- a/libavcodec/pcx.c
+++ b/libavcodec/pcx.c
@@ -22,13 +22,11 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
-#include "libavutil/imgutils.h"
 #include "avcodec.h"
 #include "bytestream.h"
 #include "codec_internal.h"
 #include "decode.h"
 #include "get_bits.h"
-#include "internal.h"
 
 #define PCX_HEADER_SIZE 128
 
diff --git a/libavcodec/pgssubdec.c b/libavcodec/pgssubdec.c
index 13c570c3c2..69aabfe2b0 100644
--- a/libavcodec/pgssubdec.c
+++ b/libavcodec/pgssubdec.c
@@ -27,11 +27,10 @@
 #include "avcodec.h"
 #include "bytestream.h"
 #include "codec_internal.h"
-#include "internal.h"
+#include "decode.h"
 #include "mathops.h"
 
 #include "libavutil/colorspace.h"
-#include "libavutil/imgutils.h"
 #include "libavutil/opt.h"
 
 #define RGBA(r,g,b,a) (((unsigned)(a) << 24) | ((r) << 16) | ((g) << 8) | (b))
diff --git a/libavcodec/pgxdec.c b/libavcodec/pgxdec.c
index dcbf2a32dd..177ad66468 100644
--- a/libavcodec/pgxdec.c
+++ b/libavcodec/pgxdec.c
@@ -20,7 +20,6 @@
  */
 
 #include "avcodec.h"
-#include "internal.h"
 #include "bytestream.h"
 #include "codec_internal.h"
 #include "decode.h"
diff --git a/libavcodec/photocd.c b/libavcodec/photocd.c
index 239b7a1b54..b31666d78a 100644
--- a/libavcodec/photocd.c
+++ b/libavcodec/photocd.c
@@ -36,8 +36,8 @@
 #include "avcodec.h"
 #include "bytestream.h"
 #include "codec_internal.h"
+#include "decode.h"
 #include "get_bits.h"
-#include "internal.h"
 #include "thread.h"
 
 typedef struct PhotoCDContext {
diff --git a/libavcodec/pictordec.c b/libavcodec/pictordec.c
index f215f0d220..fcd9e8a9ed 100644
--- a/libavcodec/pictordec.c
+++ b/libavcodec/pictordec.c
@@ -30,7 +30,6 @@
 #include "cga_data.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 
 typedef struct PicContext {
     int width, height;
diff --git a/libavcodec/pixlet.c b/libavcodec/pixlet.c
index 1f43b4c8e0..d7c40052a5 100644
--- a/libavcodec/pixlet.c
+++ b/libavcodec/pixlet.c
@@ -21,15 +21,13 @@
 
 #include <stdint.h>
 
-#include "libavutil/imgutils.h"
 #include "libavutil/intmath.h"
-#include "libavutil/opt.h"
 
 #include "avcodec.h"
 #include "bytestream.h"
 #include "codec_internal.h"
+#include "decode.h"
 #include "get_bits.h"
-#include "internal.h"
 #include "thread.h"
 #include "unary.h"
 
diff --git a/libavcodec/pngdec.c b/libavcodec/pngdec.c
index 1d6ca7f4c3..7cb3d98bd6 100644
--- a/libavcodec/pngdec.c
+++ b/libavcodec/pngdec.c
@@ -34,7 +34,7 @@
 #include "avcodec.h"
 #include "bytestream.h"
 #include "codec_internal.h"
-#include "internal.h"
+#include "decode.h"
 #include "apng.h"
 #include "png.h"
 #include "pngdsp.h"
diff --git a/libavcodec/pnm.c b/libavcodec/pnm.c
index aabc788684..77d24eeaf7 100644
--- a/libavcodec/pnm.c
+++ b/libavcodec/pnm.c
@@ -26,7 +26,7 @@
 #include "libavutil/imgutils.h"
 #include "libavutil/avstring.h"
 #include "avcodec.h"
-#include "internal.h"
+#include "decode.h"
 #include "pnm.h"
 
 static inline int pnm_space(int c)
diff --git a/libavcodec/proresdec2.c b/libavcodec/proresdec2.c
index 659f9ff16b..df864c77ec 100644
--- a/libavcodec/proresdec2.c
+++ b/libavcodec/proresdec2.c
@@ -35,12 +35,11 @@
 
 #include "avcodec.h"
 #include "codec_internal.h"
+#include "decode.h"
 #include "get_bits.h"
 #include "hwconfig.h"
 #include "idctdsp.h"
-#include "internal.h"
 #include "profiles.h"
-#include "simple_idct.h"
 #include "proresdec.h"
 #include "proresdata.h"
 #include "thread.h"
diff --git a/libavcodec/psd.c b/libavcodec/psd.c
index 5a5c57e856..3ac3f46dd5 100644
--- a/libavcodec/psd.c
+++ b/libavcodec/psd.c
@@ -22,7 +22,6 @@
 #include "bytestream.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 
 enum PsdCompr {
     PSD_RAW,
diff --git a/libavcodec/ptx.c b/libavcodec/ptx.c
index 412df4d763..84fe1872d2 100644
--- a/libavcodec/ptx.c
+++ b/libavcodec/ptx.c
@@ -24,7 +24,6 @@
 #include "avcodec.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 
 static int ptx_decode_frame(AVCodecContext *avctx, AVFrame *p,
                             int *got_frame, AVPacket *avpkt)
diff --git a/libavcodec/qdrw.c b/libavcodec/qdrw.c
index 1aac7c8010..4405ff2b4e 100644
--- a/libavcodec/qdrw.c
+++ b/libavcodec/qdrw.c
@@ -32,7 +32,6 @@
 #include "bytestream.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 
 enum QuickdrawOpcodes {
     CLIP = 0x0001,
diff --git a/libavcodec/qoidec.c b/libavcodec/qoidec.c
index 1e052f659b..1053d784a2 100644
--- a/libavcodec/qoidec.c
+++ b/libavcodec/qoidec.c
@@ -18,13 +18,10 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
-#include <stdlib.h>
-
-#include "libavutil/imgutils.h"
 #include "avcodec.h"
-#include "internal.h"
 #include "bytestream.h"
 #include "codec_internal.h"
+#include "decode.h"
 #include "thread.h"
 #include "qoi.h"
 
diff --git a/libavcodec/rasc.c b/libavcodec/rasc.c
index a74b4d145c..a04dff6d90 100644
--- a/libavcodec/rasc.c
+++ b/libavcodec/rasc.c
@@ -29,7 +29,6 @@
 #include "bytestream.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 #include "zlib_wrapper.h"
 
 #include <zlib.h>
diff --git a/libavcodec/rl2.c b/libavcodec/rl2.c
index e7c3800f9e..2e6f555b8c 100644
--- a/libavcodec/rl2.c
+++ b/libavcodec/rl2.c
@@ -26,8 +26,6 @@
  * @see http://wiki.multimedia.cx/index.php?title=RL2
  */
 
-#include <stdio.h>
-#include <stdlib.h>
 #include <string.h>
 
 #include "libavutil/internal.h"
@@ -36,7 +34,6 @@
 #include "avcodec.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 
 
 #define EXTRADATA1_SIZE (6 + 256 * 3) ///< video base, clr count, palette
diff --git a/libavcodec/rv10.c b/libavcodec/rv10.c
index abf42612cb..d8b8900795 100644
--- a/libavcodec/rv10.c
+++ b/libavcodec/rv10.c
@@ -32,11 +32,11 @@
 
 #include "avcodec.h"
 #include "codec_internal.h"
+#include "decode.h"
 #include "error_resilience.h"
 #include "h263.h"
 #include "h263data.h"
 #include "h263dec.h"
-#include "internal.h"
 #include "mpeg_er.h"
 #include "mpegutils.h"
 #include "mpegvideo.h"
diff --git a/libavcodec/rv34.c b/libavcodec/rv34.c
index 61d1e4c527..acf77d103d 100644
--- a/libavcodec/rv34.c
+++ b/libavcodec/rv34.c
@@ -29,15 +29,14 @@
 #include "libavutil/internal.h"
 #include "libavutil/mem_internal.h"
 #include "libavutil/thread.h"
-#include "libavutil/video_enc_params.h"
 
 #include "avcodec.h"
+#include "decode.h"
 #include "error_resilience.h"
 #include "mpegutils.h"
 #include "mpegvideo.h"
 #include "mpegvideodec.h"
 #include "golomb.h"
-#include "internal.h"
 #include "mathops.h"
 #include "mpeg_er.h"
 #include "qpeldsp.h"
diff --git a/libavcodec/sanm.c b/libavcodec/sanm.c
index 064e812e51..aceddaf835 100644
--- a/libavcodec/sanm.c
+++ b/libavcodec/sanm.c
@@ -21,15 +21,12 @@
  */
 
 #include "libavutil/avassert.h"
-#include "libavutil/bswap.h"
-#include "libavutil/imgutils.h"
 
 #include "avcodec.h"
 #include "bytestream.h"
 #include "copy_block.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 
 #define NGLYPHS 256
 #define GLYPH_COORD_VECT_SIZE 16
diff --git a/libavcodec/sga.c b/libavcodec/sga.c
index febe950424..296ab5dd5d 100644
--- a/libavcodec/sga.c
+++ b/libavcodec/sga.c
@@ -24,7 +24,6 @@
 #include "bytestream.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 
 #define PALDATA_FOLLOWS_TILEDATA 4
 #define HAVE_COMPRESSED_TILEMAP 32
diff --git a/libavcodec/sgidec.c b/libavcodec/sgidec.c
index c1070d5c95..e33a739ecd 100644
--- a/libavcodec/sgidec.c
+++ b/libavcodec/sgidec.c
@@ -19,12 +19,10 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
-#include "libavutil/imgutils.h"
 #include "avcodec.h"
 #include "bytestream.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 #include "sgi.h"
 
 typedef struct SgiState {
diff --git a/libavcodec/sunrast.c b/libavcodec/sunrast.c
index 51695c353c..ee648ba95d 100644
--- a/libavcodec/sunrast.c
+++ b/libavcodec/sunrast.c
@@ -21,11 +21,9 @@
 
 #include "libavutil/common.h"
 #include "libavutil/intreadwrite.h"
-#include "libavutil/imgutils.h"
 #include "avcodec.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 #include "sunrast.h"
 
 static int sunrast_decode_frame(AVCodecContext *avctx, AVFrame *p,
diff --git a/libavcodec/svq1dec.c b/libavcodec/svq1dec.c
index e091e4279f..c96f65249a 100644
--- a/libavcodec/svq1dec.c
+++ b/libavcodec/svq1dec.c
@@ -41,7 +41,6 @@
 #include "get_bits.h"
 #include "h263data.h"
 #include "hpeldsp.h"
-#include "internal.h"
 #include "mathops.h"
 #include "svq1.h"
 
diff --git a/libavcodec/svq3.c b/libavcodec/svq3.c
index d4fff0557b..ea9842f9b4 100644
--- a/libavcodec/svq3.c
+++ b/libavcodec/svq3.c
@@ -48,7 +48,6 @@
 
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 #include "avcodec.h"
 #include "mpegutils.h"
 #include "h264data.h"
@@ -66,8 +65,6 @@
 #include <zlib.h>
 #endif
 
-#include "svq1.h"
-
 /**
  * @file
  * svq3 decoder.
diff --git a/libavcodec/targa.c b/libavcodec/targa.c
index 2901d908de..bbf4f6ca19 100644
--- a/libavcodec/targa.c
+++ b/libavcodec/targa.c
@@ -19,13 +19,10 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
-#include "libavutil/intreadwrite.h"
-#include "libavutil/imgutils.h"
 #include "avcodec.h"
 #include "bytestream.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 #include "targa.h"
 
 typedef struct TargaContext {
diff --git a/libavcodec/tdsc.c b/libavcodec/tdsc.c
index c4e4d35ee8..aeb1ea363e 100644
--- a/libavcodec/tdsc.c
+++ b/libavcodec/tdsc.c
@@ -42,7 +42,6 @@
 #include "bytestream.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 
 #define BITMAPINFOHEADER_SIZE 0x28
 #define TDSF_HEADER_SIZE      0x56
diff --git a/libavcodec/tiertexseqv.c b/libavcodec/tiertexseqv.c
index 9e1b10a40c..785ccfbdcf 100644
--- a/libavcodec/tiertexseqv.c
+++ b/libavcodec/tiertexseqv.c
@@ -29,7 +29,6 @@
 #include "codec_internal.h"
 #include "decode.h"
 #include "get_bits.h"
-#include "internal.h"
 
 
 typedef struct SeqVideoContext {
diff --git a/libavcodec/tiff.c b/libavcodec/tiff.c
index 043ff79e0a..b0595b56c0 100644
--- a/libavcodec/tiff.c
+++ b/libavcodec/tiff.c
@@ -34,19 +34,16 @@
 #endif
 
 #include "libavutil/attributes.h"
-#include "libavutil/avstring.h"
 #include "libavutil/error.h"
 #include "libavutil/intreadwrite.h"
-#include "libavutil/imgutils.h"
 #include "libavutil/opt.h"
 #include "libavutil/reverse.h"
 #include "avcodec.h"
 #include "bytestream.h"
 #include "codec_internal.h"
+#include "decode.h"
 #include "faxcompr.h"
-#include "internal.h"
 #include "lzw.h"
-#include "mathops.h"
 #include "tiff.h"
 #include "tiff_data.h"
 #include "mjpegdec.h"
diff --git a/libavcodec/truemotion1.c b/libavcodec/truemotion1.c
index ee41b0ed4d..ab632e99dc 100644
--- a/libavcodec/truemotion1.c
+++ b/libavcodec/truemotion1.c
@@ -36,7 +36,6 @@
 #include "avcodec.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 #include "libavutil/imgutils.h"
 #include "libavutil/internal.h"
 #include "libavutil/intreadwrite.h"
diff --git a/libavcodec/truemotion2rt.c b/libavcodec/truemotion2rt.c
index 265ca87456..a0bf4749f3 100644
--- a/libavcodec/truemotion2rt.c
+++ b/libavcodec/truemotion2rt.c
@@ -18,11 +18,6 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-
-#include "libavutil/imgutils.h"
 #include "libavutil/internal.h"
 #include "libavutil/intreadwrite.h"
 
@@ -31,7 +26,6 @@
 #include "codec_internal.h"
 #include "decode.h"
 #include "get_bits.h"
-#include "internal.h"
 
 typedef struct TrueMotion2RTContext {
     GetBitContext gb;
diff --git a/libavcodec/txd.c b/libavcodec/txd.c
index 8862f14bd8..7e8b33646b 100644
--- a/libavcodec/txd.c
+++ b/libavcodec/txd.c
@@ -21,13 +21,10 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
-#include "libavutil/intreadwrite.h"
-#include "libavutil/imgutils.h"
 #include "bytestream.h"
 #include "avcodec.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 #include "texturedsp.h"
 
 #define TXD_DXT1 0x31545844
diff --git a/libavcodec/v4l2_context.c b/libavcodec/v4l2_context.c
index e891649f92..a40be94690 100644
--- a/libavcodec/v4l2_context.c
+++ b/libavcodec/v4l2_context.c
@@ -28,7 +28,7 @@
 #include <fcntl.h>
 #include <poll.h>
 #include "libavcodec/avcodec.h"
-#include "libavcodec/internal.h"
+#include "decode.h"
 #include "v4l2_buffers.h"
 #include "v4l2_fmt.h"
 #include "v4l2_m2m.h"
diff --git a/libavcodec/vbndec.c b/libavcodec/vbndec.c
index 706760f376..d8a3c61c8c 100644
--- a/libavcodec/vbndec.c
+++ b/libavcodec/vbndec.c
@@ -27,7 +27,6 @@
 #include "bytestream.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 #include "texturedsp.h"
 #include "vbn.h"
 #include "libavutil/imgutils.h"
diff --git a/libavcodec/vc1.c b/libavcodec/vc1.c
index d46f551020..c9257b290f 100644
--- a/libavcodec/vc1.c
+++ b/libavcodec/vc1.c
@@ -28,7 +28,6 @@
 
 #include "libavutil/attributes.h"
 #include "libavutil/thread.h"
-#include "internal.h"
 #include "avcodec.h"
 #include "decode.h"
 #include "mpegvideo.h"
diff --git a/libavcodec/vp3.c b/libavcodec/vp3.c
index 0f040c338f..4734025244 100644
--- a/libavcodec/vp3.c
+++ b/libavcodec/vp3.c
@@ -32,8 +32,7 @@
 
 #include "config_components.h"
 
-#include <stdio.h>
-#include <stdlib.h>
+#include <stddef.h>
 #include <string.h>
 
 #include "libavutil/imgutils.h"
@@ -44,7 +43,6 @@
 #include "decode.h"
 #include "get_bits.h"
 #include "hpeldsp.h"
-#include "internal.h"
 #include "mathops.h"
 #include "thread.h"
 #include "threadframe.h"
diff --git a/libavcodec/vp5.c b/libavcodec/vp5.c
index 8ba4de71e5..9ddc6fa70d 100644
--- a/libavcodec/vp5.c
+++ b/libavcodec/vp5.c
@@ -23,12 +23,11 @@
  * VP5 compatible video decoder
  */
 
-#include <stdlib.h>
 #include <string.h>
 
 #include "avcodec.h"
 #include "codec_internal.h"
-#include "internal.h"
+#include "decode.h"
 
 #include "vp56.h"
 #include "vp56data.h"
diff --git a/libavcodec/vp56.c b/libavcodec/vp56.c
index 1c58096bdb..bd994428a4 100644
--- a/libavcodec/vp56.c
+++ b/libavcodec/vp56.c
@@ -26,7 +26,6 @@
 #include "avcodec.h"
 #include "bytestream.h"
 #include "decode.h"
-#include "internal.h"
 #include "h264chroma.h"
 #include "vp56.h"
 #include "vp56data.h"
diff --git a/libavcodec/vp6.c b/libavcodec/vp6.c
index ad81060886..f7815d7398 100644
--- a/libavcodec/vp6.c
+++ b/libavcodec/vp6.c
@@ -31,9 +31,9 @@
 
 #include "avcodec.h"
 #include "codec_internal.h"
+#include "decode.h"
 #include "get_bits.h"
 #include "huffman.h"
-#include "internal.h"
 
 #include "vp56.h"
 #include "vp56data.h"
diff --git a/libavcodec/vp8.c b/libavcodec/vp8.c
index 6bf846dbfe..ab38c76735 100644
--- a/libavcodec/vp8.c
+++ b/libavcodec/vp8.c
@@ -26,16 +26,13 @@
 
 #include "config_components.h"
 
-#include "libavutil/imgutils.h"
 #include "libavutil/mem_internal.h"
 
 #include "avcodec.h"
 #include "codec_internal.h"
 #include "decode.h"
 #include "hwconfig.h"
-#include "internal.h"
 #include "mathops.h"
-#include "rectangle.h"
 #include "thread.h"
 #include "threadframe.h"
 #include "vp8.h"
diff --git a/libavcodec/vp9.c b/libavcodec/vp9.c
index 621627ddc5..fe85c17133 100644
--- a/libavcodec/vp9.c
+++ b/libavcodec/vp9.c
@@ -25,9 +25,9 @@
 
 #include "avcodec.h"
 #include "codec_internal.h"
+#include "decode.h"
 #include "get_bits.h"
 #include "hwconfig.h"
-#include "internal.h"
 #include "profiles.h"
 #include "thread.h"
 #include "threadframe.h"
diff --git a/libavcodec/vqavideo.c b/libavcodec/vqavideo.c
index 61c30c2a62..4006b1433c 100644
--- a/libavcodec/vqavideo.c
+++ b/libavcodec/vqavideo.c
@@ -70,16 +70,13 @@
  */
 
 #include <stdio.h>
-#include <stdlib.h>
 #include <string.h>
 
 #include "libavutil/intreadwrite.h"
-#include "libavutil/imgutils.h"
 #include "avcodec.h"
 #include "bytestream.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 
 #define PALETTE_COUNT 256
 #define VQA_HEADER_SIZE 0x2A
diff --git a/libavcodec/wbmpdec.c b/libavcodec/wbmpdec.c
index 0d0e574d9c..c289b08bcc 100644
--- a/libavcodec/wbmpdec.c
+++ b/libavcodec/wbmpdec.c
@@ -21,7 +21,7 @@
 #include "avcodec.h"
 #include "bytestream.h"
 #include "codec_internal.h"
-#include "internal.h"
+#include "decode.h"
 #include "thread.h"
 
 static unsigned int getv(GetByteContext * gb)
diff --git a/libavcodec/webp.c b/libavcodec/webp.c
index fb5688fc95..dca5e451f2 100644
--- a/libavcodec/webp.c
+++ b/libavcodec/webp.c
@@ -46,9 +46,9 @@
 #include "avcodec.h"
 #include "bytestream.h"
 #include "codec_internal.h"
+#include "decode.h"
 #include "exif.h"
 #include "get_bits.h"
-#include "internal.h"
 #include "thread.h"
 #include "tiff_common.h"
 #include "vp8.h"
diff --git a/libavcodec/xbmdec.c b/libavcodec/xbmdec.c
index a28da08a29..f38f9dd1e8 100644
--- a/libavcodec/xbmdec.c
+++ b/libavcodec/xbmdec.c
@@ -20,14 +20,11 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
-#include "libavutil/avstring.h"
 #include "libavutil/reverse.h"
 
 #include "avcodec.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
-#include "mathops.h"
 
 static int get_nibble(uint8_t x)
 {
diff --git a/libavcodec/xpmdec.c b/libavcodec/xpmdec.c
index a1d5635874..c005dc1e3a 100644
--- a/libavcodec/xpmdec.c
+++ b/libavcodec/xpmdec.c
@@ -25,7 +25,6 @@
 #include "avcodec.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 
 #define MIN_ELEMENT ' '
 #define MAX_ELEMENT 0xfe
diff --git a/libavcodec/xwddec.c b/libavcodec/xwddec.c
index 43d4bb5e84..f3703292ca 100644
--- a/libavcodec/xwddec.c
+++ b/libavcodec/xwddec.c
@@ -27,7 +27,6 @@
 #include "bytestream.h"
 #include "codec_internal.h"
 #include "decode.h"
-#include "internal.h"
 #include "xwd.h"
 
 static int xwd_decode_frame(AVCodecContext *avctx, AVFrame *p,




More information about the ffmpeg-cvslog mailing list