aboutsummaryrefslogtreecommitdiffstats
path: root/src/decoder
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2013-11-28 11:50:54 +0100
committerMax Kellermann <max@duempel.org>2013-11-28 11:50:54 +0100
commitf90abe9530ef1075bc9b60e0f08f405d2d86f799 (patch)
tree60f4052123e03cd326ec64f4b6cd711784d651b2 /src/decoder
parent46bab7e4b921b79924643bacd08dcd3d1404ceb6 (diff)
downloadmpd-f90abe9530ef1075bc9b60e0f08f405d2d86f799.tar.gz
mpd-f90abe9530ef1075bc9b60e0f08f405d2d86f799.tar.xz
mpd-f90abe9530ef1075bc9b60e0f08f405d2d86f799.zip
include cleanup using iwyu
Diffstat (limited to 'src/decoder')
-rw-r--r--src/decoder/DsdLib.cxx2
-rw-r--r--src/decoder/DsdiffDecoderPlugin.cxx3
-rw-r--r--src/decoder/DsfDecoderPlugin.cxx3
-rw-r--r--src/decoder/FfmpegDecoderPlugin.cxx1
-rw-r--r--src/decoder/FfmpegMetaData.hxx4
-rw-r--r--src/decoder/FlacCommon.cxx4
-rw-r--r--src/decoder/FlacCommon.hxx1
-rw-r--r--src/decoder/FlacDecoderPlugin.cxx4
-rw-r--r--src/decoder/FlacMetadata.cxx2
-rw-r--r--src/decoder/FlacMetadata.hxx6
-rw-r--r--src/decoder/MadDecoderPlugin.cxx1
-rw-r--r--src/decoder/MikmodDecoderPlugin.cxx2
-rw-r--r--src/decoder/MpcdecDecoderPlugin.cxx2
-rw-r--r--src/decoder/Mpg123DecoderPlugin.cxx3
-rw-r--r--src/decoder/OggCodec.cxx1
-rw-r--r--src/decoder/OggCodec.hxx3
-rw-r--r--src/decoder/OggFind.hxx1
-rw-r--r--src/decoder/OpusDecoderPlugin.cxx2
-rw-r--r--src/decoder/OpusHead.cxx1
-rw-r--r--src/decoder/PcmDecoderPlugin.cxx2
-rw-r--r--src/decoder/VorbisComments.cxx2
-rw-r--r--src/decoder/VorbisComments.hxx2
-rw-r--r--src/decoder/VorbisDecoderPlugin.cxx3
-rw-r--r--src/decoder/VorbisDomain.hxx4
24 files changed, 13 insertions, 46 deletions
diff --git a/src/decoder/DsdLib.cxx b/src/decoder/DsdLib.cxx
index 67cc7e945..b0ba73126 100644
--- a/src/decoder/DsdLib.cxx
+++ b/src/decoder/DsdLib.cxx
@@ -27,8 +27,6 @@
#include "DsdLib.hxx"
#include "DecoderAPI.hxx"
#include "InputStream.hxx"
-#include "util/bit_reverse.h"
-#include "tag/TagHandler.hxx"
#include "tag/TagId3.hxx"
#include "util/Error.hxx"
diff --git a/src/decoder/DsdiffDecoderPlugin.cxx b/src/decoder/DsdiffDecoderPlugin.cxx
index a3c0149b9..bc9fc2353 100644
--- a/src/decoder/DsdiffDecoderPlugin.cxx
+++ b/src/decoder/DsdiffDecoderPlugin.cxx
@@ -38,9 +38,6 @@
#include "DsdLib.hxx"
#include "Log.hxx"
-#include <unistd.h>
-#include <stdio.h> /* for SEEK_SET, SEEK_CUR */
-
struct DsdiffHeader {
DsdId id;
DffDsdUint64 size;
diff --git a/src/decoder/DsfDecoderPlugin.cxx b/src/decoder/DsfDecoderPlugin.cxx
index 5ef94e647..ab96e8ce6 100644
--- a/src/decoder/DsfDecoderPlugin.cxx
+++ b/src/decoder/DsfDecoderPlugin.cxx
@@ -39,9 +39,6 @@
#include "tag/TagHandler.hxx"
#include "Log.hxx"
-#include <unistd.h>
-#include <stdio.h> /* for SEEK_SET, SEEK_CUR */
-
struct DsfMetaData {
unsigned sample_rate, channels;
bool bitreverse;
diff --git a/src/decoder/FfmpegDecoderPlugin.cxx b/src/decoder/FfmpegDecoderPlugin.cxx
index 1b62eae57..bef74e367 100644
--- a/src/decoder/FfmpegDecoderPlugin.cxx
+++ b/src/decoder/FfmpegDecoderPlugin.cxx
@@ -38,7 +38,6 @@ extern "C" {
#include <libavutil/avutil.h>
#include <libavutil/log.h>
#include <libavutil/mathematics.h>
-#include <libavutil/dict.h>
}
#include <assert.h>
diff --git a/src/decoder/FfmpegMetaData.hxx b/src/decoder/FfmpegMetaData.hxx
index 0fd73df04..998cdf5a8 100644
--- a/src/decoder/FfmpegMetaData.hxx
+++ b/src/decoder/FfmpegMetaData.hxx
@@ -21,8 +21,6 @@
#define MPD_FFMPEG_METADATA_HXX
extern "C" {
-#include <libavformat/avformat.h>
-#include <libavutil/avutil.h>
#include <libavutil/dict.h>
}
@@ -35,6 +33,6 @@ struct tag_handler;
void
ffmpeg_scan_dictionary(AVDictionary *dict,
- const struct tag_handler *handler, void *handler_ctx);
+ const tag_handler *handler, void *handler_ctx);
#endif
diff --git a/src/decoder/FlacCommon.cxx b/src/decoder/FlacCommon.cxx
index e4b906c12..e355f285a 100644
--- a/src/decoder/FlacCommon.cxx
+++ b/src/decoder/FlacCommon.cxx
@@ -25,14 +25,10 @@
#include "FlacCommon.hxx"
#include "FlacMetadata.hxx"
#include "FlacPcm.hxx"
-#include "MixRampInfo.hxx"
#include "CheckAudioFormat.hxx"
#include "util/Error.hxx"
-#include "util/Domain.hxx"
#include "Log.hxx"
-#include <assert.h>
-
flac_data::flac_data(Decoder &_decoder,
InputStream &_input_stream)
:FlacInput(_input_stream, &_decoder),
diff --git a/src/decoder/FlacCommon.hxx b/src/decoder/FlacCommon.hxx
index de000dfa1..0f6b09973 100644
--- a/src/decoder/FlacCommon.hxx
+++ b/src/decoder/FlacCommon.hxx
@@ -29,7 +29,6 @@
#include "pcm/PcmBuffer.hxx"
#include <FLAC/stream_decoder.h>
-#include <FLAC/metadata.h>
struct flac_data : public FlacInput {
PcmBuffer buffer;
diff --git a/src/decoder/FlacDecoderPlugin.cxx b/src/decoder/FlacDecoderPlugin.cxx
index 1b5734434..2c811a8e0 100644
--- a/src/decoder/FlacDecoderPlugin.cxx
+++ b/src/decoder/FlacDecoderPlugin.cxx
@@ -26,10 +26,6 @@
#include "util/Error.hxx"
#include "Log.hxx"
-#include <glib.h>
-
-#include <assert.h>
-
#if !defined(FLAC_API_VERSION_CURRENT) || FLAC_API_VERSION_CURRENT <= 7
#error libFLAC is too old
#endif
diff --git a/src/decoder/FlacMetadata.cxx b/src/decoder/FlacMetadata.cxx
index 17cc4cd8d..9cbedd67b 100644
--- a/src/decoder/FlacMetadata.cxx
+++ b/src/decoder/FlacMetadata.cxx
@@ -21,7 +21,6 @@
#include "FlacMetadata.hxx"
#include "XiphTags.hxx"
#include "MixRampInfo.hxx"
-#include "tag/Tag.hxx"
#include "tag/TagHandler.hxx"
#include "tag/TagTable.hxx"
#include "tag/TagBuilder.hxx"
@@ -30,7 +29,6 @@
#include <glib.h>
-#include <assert.h>
#include <string.h>
static bool
diff --git a/src/decoder/FlacMetadata.hxx b/src/decoder/FlacMetadata.hxx
index 96c61b8e6..137101a65 100644
--- a/src/decoder/FlacMetadata.hxx
+++ b/src/decoder/FlacMetadata.hxx
@@ -27,6 +27,7 @@
#include <assert.h>
+struct tag_handler;
class MixRampInfo;
class FlacMetadataChain {
@@ -81,7 +82,7 @@ public:
return FLAC__Metadata_ChainStatusString[GetStatus()];
}
- void Scan(const struct tag_handler *handler, void *handler_ctx);
+ void Scan(const tag_handler *handler, void *handler_ctx);
};
class FLACMetadataIterator {
@@ -110,7 +111,6 @@ public:
}
};
-struct tag_handler;
struct Tag;
struct ReplayGainInfo;
@@ -136,6 +136,6 @@ flac_vorbis_comments_to_tag(Tag &tag,
void
flac_scan_metadata(const FLAC__StreamMetadata *block,
- const struct tag_handler *handler, void *handler_ctx);
+ const tag_handler *handler, void *handler_ctx);
#endif
diff --git a/src/decoder/MadDecoderPlugin.cxx b/src/decoder/MadDecoderPlugin.cxx
index 9dd86c55f..4dfb752f0 100644
--- a/src/decoder/MadDecoderPlugin.cxx
+++ b/src/decoder/MadDecoderPlugin.cxx
@@ -32,7 +32,6 @@
#include "Log.hxx"
#include <assert.h>
-#include <unistd.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
diff --git a/src/decoder/MikmodDecoderPlugin.cxx b/src/decoder/MikmodDecoderPlugin.cxx
index 34381aafa..93a3cc280 100644
--- a/src/decoder/MikmodDecoderPlugin.cxx
+++ b/src/decoder/MikmodDecoderPlugin.cxx
@@ -25,8 +25,8 @@
#include "util/Domain.hxx"
#include "Log.hxx"
-#include <glib.h>
#include <mikmod.h>
+
#include <assert.h>
static constexpr Domain mikmod_domain("mikmod");
diff --git a/src/decoder/MpcdecDecoderPlugin.cxx b/src/decoder/MpcdecDecoderPlugin.cxx
index dc258623c..620bfad30 100644
--- a/src/decoder/MpcdecDecoderPlugin.cxx
+++ b/src/decoder/MpcdecDecoderPlugin.cxx
@@ -30,8 +30,6 @@
#include <mpc/mpcdec.h>
-#include <assert.h>
-#include <unistd.h>
#include <math.h>
struct mpc_decoder_data {
diff --git a/src/decoder/Mpg123DecoderPlugin.cxx b/src/decoder/Mpg123DecoderPlugin.cxx
index df23f7847..895c8b865 100644
--- a/src/decoder/Mpg123DecoderPlugin.cxx
+++ b/src/decoder/Mpg123DecoderPlugin.cxx
@@ -26,9 +26,8 @@
#include "util/Domain.hxx"
#include "Log.hxx"
-#include <glib.h>
-
#include <mpg123.h>
+
#include <stdio.h>
static constexpr Domain mpg123_domain("mpg123");
diff --git a/src/decoder/OggCodec.cxx b/src/decoder/OggCodec.cxx
index 565dbafcf..cc6cd20c0 100644
--- a/src/decoder/OggCodec.cxx
+++ b/src/decoder/OggCodec.cxx
@@ -23,6 +23,7 @@
#include "config.h"
#include "OggCodec.hxx"
+#include "DecoderAPI.hxx"
#include <string.h>
diff --git a/src/decoder/OggCodec.hxx b/src/decoder/OggCodec.hxx
index 857871607..13eab2cdb 100644
--- a/src/decoder/OggCodec.hxx
+++ b/src/decoder/OggCodec.hxx
@@ -24,7 +24,8 @@
#ifndef MPD_OGG_CODEC_HXX
#define MPD_OGG_CODEC_HXX
-#include "DecoderAPI.hxx"
+struct Decoder;
+struct InputStream;
enum ogg_codec {
OGG_CODEC_UNKNOWN,
diff --git a/src/decoder/OggFind.hxx b/src/decoder/OggFind.hxx
index ad51ccdf3..a329e42a4 100644
--- a/src/decoder/OggFind.hxx
+++ b/src/decoder/OggFind.hxx
@@ -25,7 +25,6 @@
#include <ogg/ogg.h>
-struct InputStream;
class OggSyncState;
/**
diff --git a/src/decoder/OpusDecoderPlugin.cxx b/src/decoder/OpusDecoderPlugin.cxx
index f3d7b342e..201d61d96 100644
--- a/src/decoder/OpusDecoderPlugin.cxx
+++ b/src/decoder/OpusDecoderPlugin.cxx
@@ -22,12 +22,10 @@
#include "OpusDomain.hxx"
#include "OpusHead.hxx"
#include "OpusTags.hxx"
-#include "OggUtil.hxx"
#include "OggFind.hxx"
#include "OggSyncState.hxx"
#include "DecoderAPI.hxx"
#include "OggCodec.hxx"
-#include "CheckAudioFormat.hxx"
#include "tag/TagHandler.hxx"
#include "tag/TagBuilder.hxx"
#include "InputStream.hxx"
diff --git a/src/decoder/OpusHead.cxx b/src/decoder/OpusHead.cxx
index 0417d3905..dd2b125b0 100644
--- a/src/decoder/OpusHead.cxx
+++ b/src/decoder/OpusHead.cxx
@@ -21,7 +21,6 @@
#include "OpusHead.hxx"
#include <stdint.h>
-#include <string.h>
struct OpusHead {
char signature[8];
diff --git a/src/decoder/PcmDecoderPlugin.cxx b/src/decoder/PcmDecoderPlugin.cxx
index dbc38fb76..0bef8dc69 100644
--- a/src/decoder/PcmDecoderPlugin.cxx
+++ b/src/decoder/PcmDecoderPlugin.cxx
@@ -25,8 +25,6 @@
#include "util/ByteReverse.hxx"
#include "Log.hxx"
-#include <glib.h>
-#include <unistd.h>
#include <string.h>
#include <stdio.h> /* for SEEK_SET */
diff --git a/src/decoder/VorbisComments.cxx b/src/decoder/VorbisComments.cxx
index d4f019b58..5a9e6a82e 100644
--- a/src/decoder/VorbisComments.cxx
+++ b/src/decoder/VorbisComments.cxx
@@ -20,7 +20,6 @@
#include "config.h"
#include "VorbisComments.hxx"
#include "XiphTags.hxx"
-#include "tag/Tag.hxx"
#include "tag/TagTable.hxx"
#include "tag/TagHandler.hxx"
#include "tag/TagBuilder.hxx"
@@ -29,7 +28,6 @@
#include <glib.h>
-#include <assert.h>
#include <stddef.h>
#include <string.h>
#include <stdlib.h>
diff --git a/src/decoder/VorbisComments.hxx b/src/decoder/VorbisComments.hxx
index e5a48ef6b..f537bf30f 100644
--- a/src/decoder/VorbisComments.hxx
+++ b/src/decoder/VorbisComments.hxx
@@ -31,7 +31,7 @@ vorbis_comments_to_replay_gain(ReplayGainInfo &rgi, char **comments);
void
vorbis_comments_scan(char **comments,
- const struct tag_handler *handler, void *handler_ctx);
+ const tag_handler *handler, void *handler_ctx);
Tag *
vorbis_comments_to_tag(char **comments);
diff --git a/src/decoder/VorbisDecoderPlugin.cxx b/src/decoder/VorbisDecoderPlugin.cxx
index 4d3e48528..a637241b1 100644
--- a/src/decoder/VorbisDecoderPlugin.cxx
+++ b/src/decoder/VorbisDecoderPlugin.cxx
@@ -25,9 +25,7 @@
#include "InputStream.hxx"
#include "OggCodec.hxx"
#include "util/Error.hxx"
-#include "util/UriUtil.hxx"
#include "util/Macros.hxx"
-#include "system/ByteOrder.hxx"
#include "CheckAudioFormat.hxx"
#include "tag/TagHandler.hxx"
#include "Log.hxx"
@@ -48,7 +46,6 @@
#define ov_time_seek_page(VF, S) (ov_time_seek_page(VF, (S)*1000))
#endif /* HAVE_TREMOR */
-#include <assert.h>
#include <errno.h>
struct vorbis_input_stream {
diff --git a/src/decoder/VorbisDomain.hxx b/src/decoder/VorbisDomain.hxx
index a35edd041..7946bf52a 100644
--- a/src/decoder/VorbisDomain.hxx
+++ b/src/decoder/VorbisDomain.hxx
@@ -22,6 +22,8 @@
#include "check.h"
-extern const class Domain vorbis_domain;
+class Domain;
+
+extern const Domain vorbis_domain;
#endif