diff options
author | Anton Khirnov <anton@khirnov.net> | 2020-04-07 16:41:48 +0200 |
---|---|---|
committer | Anton Khirnov <anton@khirnov.net> | 2020-04-10 14:15:14 +0200 |
commit | 672946c7fe6de56ccf5d2271ad1bfeb2290f394f (patch) | |
tree | 8306f7f04781ef2ae4597a3d1d3cd70bf25c51e3 /libavcodec/avcodec.h | |
parent | c6978418b836180c349aea3512f0a96227ecfc9b (diff) | |
download | ffmpeg-672946c7fe6de56ccf5d2271ad1bfeb2290f394f.tar.gz |
avcodec.h: split AVCodecDescriptor API into its own header
Diffstat (limited to 'libavcodec/avcodec.h')
-rw-r--r-- | libavcodec/avcodec.h | 92 |
1 files changed, 1 insertions, 91 deletions
diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h index 22eb6db00e..6da0d02a61 100644 --- a/libavcodec/avcodec.h +++ b/libavcodec/avcodec.h @@ -41,6 +41,7 @@ #include "libavutil/pixfmt.h" #include "libavutil/rational.h" +#include "codec_desc.h" #include "codec_id.h" #include "packet.h" #include "version.h" @@ -201,77 +202,6 @@ */ /** - * This struct describes the properties of a single codec described by an - * AVCodecID. - * @see avcodec_descriptor_get() - */ -typedef struct AVCodecDescriptor { - enum AVCodecID id; - enum AVMediaType type; - /** - * Name of the codec described by this descriptor. It is non-empty and - * unique for each codec descriptor. It should contain alphanumeric - * characters and '_' only. - */ - const char *name; - /** - * A more descriptive name for this codec. May be NULL. - */ - const char *long_name; - /** - * Codec properties, a combination of AV_CODEC_PROP_* flags. - */ - int props; - /** - * MIME type(s) associated with the codec. - * May be NULL; if not, a NULL-terminated array of MIME types. - * The first item is always non-NULL and is the preferred MIME type. - */ - const char *const *mime_types; - /** - * If non-NULL, an array of profiles recognized for this codec. - * Terminated with FF_PROFILE_UNKNOWN. - */ - const struct AVProfile *profiles; -} AVCodecDescriptor; - -/** - * Codec uses only intra compression. - * Video and audio codecs only. - */ -#define AV_CODEC_PROP_INTRA_ONLY (1 << 0) -/** - * Codec supports lossy compression. Audio and video codecs only. - * @note a codec may support both lossy and lossless - * compression modes - */ -#define AV_CODEC_PROP_LOSSY (1 << 1) -/** - * Codec supports lossless compression. Audio and video codecs only. - */ -#define AV_CODEC_PROP_LOSSLESS (1 << 2) -/** - * Codec supports frame reordering. That is, the coded order (the order in which - * the encoded packets are output by the encoders / stored / input to the - * decoders) may be different from the presentation order of the corresponding - * frames. - * - * For codecs that do not have this property set, PTS and DTS should always be - * equal. - */ -#define AV_CODEC_PROP_REORDER (1 << 3) -/** - * Subtitle codec is bitmap based - * Decoded AVSubtitle data can be read from the AVSubtitleRect->pict field. - */ -#define AV_CODEC_PROP_BITMAP_SUB (1 << 16) -/** - * Subtitle codec is text based. - * Decoded AVSubtitle data can be read from the AVSubtitleRect->ass field. - */ -#define AV_CODEC_PROP_TEXT_SUB (1 << 17) - -/** * @ingroup lavc_decoding * Required number of additionally allocated bytes at the end of the input bitstream for decoding. * This is mainly needed because some optimized bitstream readers read @@ -5060,26 +4990,6 @@ int av_codec_is_encoder(const AVCodec *codec); int av_codec_is_decoder(const AVCodec *codec); /** - * @return descriptor for given codec ID or NULL if no descriptor exists. - */ -const AVCodecDescriptor *avcodec_descriptor_get(enum AVCodecID id); - -/** - * Iterate over all codec descriptors known to libavcodec. - * - * @param prev previous descriptor. NULL to get the first descriptor. - * - * @return next descriptor or NULL after the last descriptor - */ -const AVCodecDescriptor *avcodec_descriptor_next(const AVCodecDescriptor *prev); - -/** - * @return codec descriptor with the given name or NULL if no such descriptor - * exists. - */ -const AVCodecDescriptor *avcodec_descriptor_get_by_name(const char *name); - -/** * Allocate a CPB properties structure and initialize its fields to default * values. * |