The enum is used by lavc, lavf and lavfi, and it is referenced by lavu, so it sementically belongs to lavu more than any other.
This change allows to drop an avcodec.h inclusion from avfilter.h. Signed-off-by: Vittorio Giovara <[email protected]> --- doc/APIchanges | 3 +++ libavcodec/avcodec.h | 14 +------------- libavfilter/af_ashowinfo.c | 1 + libavfilter/avfilter.h | 1 - libavutil/Makefile | 1 + libavutil/frame.h | 2 +- libavutil/metadata.h | 37 +++++++++++++++++++++++++++++++++++++ libavutil/version.h | 4 ++-- 8 files changed, 46 insertions(+), 17 deletions(-) create mode 100644 libavutil/metadata.h diff --git a/doc/APIchanges b/doc/APIchanges index 5934f45..5215d75 100644 --- a/doc/APIchanges +++ b/doc/APIchanges @@ -13,6 +13,9 @@ libavutil: 2014-08-09 API changes, most recent first: +2015-xx-xx - xxxxxxx - lavu 54.13.0 - metadata.h + Move AVAudioServiceType from lavc to lavu. + 2015-xx-xx - xxxxxxx - lavu 54.12.0 Add AV_LOG_TRACE for extremely verbose debugging. diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h index 3440126..2c702bc 100644 --- a/libavcodec/avcodec.h +++ b/libavcodec/avcodec.h @@ -36,6 +36,7 @@ #include "libavutil/dict.h" #include "libavutil/frame.h" #include "libavutil/log.h" +#include "libavutil/metadata.h" #include "libavutil/pixfmt.h" #include "libavutil/rational.h" @@ -572,19 +573,6 @@ enum AVDiscard{ AVDISCARD_ALL = 48, ///< discard all }; -enum AVAudioServiceType { - AV_AUDIO_SERVICE_TYPE_MAIN = 0, - AV_AUDIO_SERVICE_TYPE_EFFECTS = 1, - AV_AUDIO_SERVICE_TYPE_VISUALLY_IMPAIRED = 2, - AV_AUDIO_SERVICE_TYPE_HEARING_IMPAIRED = 3, - AV_AUDIO_SERVICE_TYPE_DIALOGUE = 4, - AV_AUDIO_SERVICE_TYPE_COMMENTARY = 5, - AV_AUDIO_SERVICE_TYPE_EMERGENCY = 6, - AV_AUDIO_SERVICE_TYPE_VOICE_OVER = 7, - AV_AUDIO_SERVICE_TYPE_KARAOKE = 8, - AV_AUDIO_SERVICE_TYPE_NB , ///< Not part of ABI -}; - /** * @ingroup lavc_encoding */ diff --git a/libavfilter/af_ashowinfo.c b/libavfilter/af_ashowinfo.c index a91d7ac..40fbd7f 100644 --- a/libavfilter/af_ashowinfo.c +++ b/libavfilter/af_ashowinfo.c @@ -33,6 +33,7 @@ #include "libavutil/downmix_info.h" #include "libavutil/intreadwrite.h" #include "libavutil/mem.h" +#include "libavutil/metadata.h" #include "libavutil/replaygain.h" #include "libavutil/samplefmt.h" diff --git a/libavfilter/avfilter.h b/libavfilter/avfilter.h index 5c41630..57aa86d 100644 --- a/libavfilter/avfilter.h +++ b/libavfilter/avfilter.h @@ -40,7 +40,6 @@ #include "libavutil/samplefmt.h" #include "libavutil/pixfmt.h" #include "libavutil/rational.h" -#include "libavcodec/avcodec.h" #include <stddef.h> diff --git a/libavutil/Makefile b/libavutil/Makefile index 0f8ed08..405a0b7 100644 --- a/libavutil/Makefile +++ b/libavutil/Makefile @@ -32,6 +32,7 @@ HEADERS = adler32.h \ macros.h \ mathematics.h \ md5.h \ + metadata.h \ mem.h \ dict.h \ old_pix_fmts.h \ diff --git a/libavutil/frame.h b/libavutil/frame.h index addcb25..ab4079d 100644 --- a/libavutil/frame.h +++ b/libavutil/frame.h @@ -90,7 +90,7 @@ enum AVFrameSideDataType { /** * This side data must be associated with an audio frame and corresponds to - * enum AVAudioServiceType defined in avcodec.h. + * enum AVAudioServiceType defined in metadata.h. */ AV_FRAME_DATA_AUDIO_SERVICE_TYPE, }; diff --git a/libavutil/metadata.h b/libavutil/metadata.h new file mode 100644 index 0000000..937581e --- /dev/null +++ b/libavutil/metadata.h @@ -0,0 +1,37 @@ +/* + * This file is part of Libav. + * + * Libav is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * Libav is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with Libav; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + */ + +#ifndef AVUTIL_METADATA_H +#define AVUTIL_METADATA_H + +#include <stdint.h> + +enum AVAudioServiceType { + AV_AUDIO_SERVICE_TYPE_MAIN = 0, + AV_AUDIO_SERVICE_TYPE_EFFECTS = 1, + AV_AUDIO_SERVICE_TYPE_VISUALLY_IMPAIRED = 2, + AV_AUDIO_SERVICE_TYPE_HEARING_IMPAIRED = 3, + AV_AUDIO_SERVICE_TYPE_DIALOGUE = 4, + AV_AUDIO_SERVICE_TYPE_COMMENTARY = 5, + AV_AUDIO_SERVICE_TYPE_EMERGENCY = 6, + AV_AUDIO_SERVICE_TYPE_VOICE_OVER = 7, + AV_AUDIO_SERVICE_TYPE_KARAOKE = 8, + AV_AUDIO_SERVICE_TYPE_NB , ///< Not part of ABI +}; + +#endif /* AVUTIL_METADATA_H */ diff --git a/libavutil/version.h b/libavutil/version.h index 9c45e0e..378f7b7 100644 --- a/libavutil/version.h +++ b/libavutil/version.h @@ -54,8 +54,8 @@ */ #define LIBAVUTIL_VERSION_MAJOR 54 -#define LIBAVUTIL_VERSION_MINOR 12 -#define LIBAVUTIL_VERSION_MICRO 1 +#define LIBAVUTIL_VERSION_MINOR 13 +#define LIBAVUTIL_VERSION_MICRO 0 #define LIBAVUTIL_VERSION_INT AV_VERSION_INT(LIBAVUTIL_VERSION_MAJOR, \ LIBAVUTIL_VERSION_MINOR, \ -- 1.9.5 (Apple Git-50.3) _______________________________________________ libav-devel mailing list [email protected] https://lists.libav.org/mailman/listinfo/libav-devel
