Unified · Split
| @@ -13,6 +13,9 @@ libavutil: 2011-04-18 · 12 unmodified lines | ||
| 13 | 13 | |
| 14 | 14 | API changes, most recent first: |
| 15 | 15 | |
| 16 | +2011-08-xx - xxxxxxx - lavc 53.8.0 | |
| 17 | + Add avcodec_get_type(). | |
| 18 | + | |
| 16 | 19 | 2011-08-06 - 2f63440 - lavf 53.4.0 |
| 17 | 20 | Add error_recognition to AVFormatContext. |
| 18 | 21 | |
| @@ -210,6 +210,7 @@ enum CodecID { · 209 unmodified lines | ||
| 210 | 210 | CODEC_ID_DFA, |
| 211 | 211 | |
| 212 | 212 | /* various PCM "codecs" */ |
| 213 | + CODEC_ID_FIRST_AUDIO = 0x10000, ///< A dummy id pointing at the start of audio codecs | |
| 213 | 214 | CODEC_ID_PCM_S16LE= 0x10000, |
| 214 | 215 | CODEC_ID_PCM_S16BE, |
| 215 | 216 | CODEC_ID_PCM_U16LE, |
| @@ -340,6 +341,7 @@ enum CodecID { · 124 unmodified lines | ||
| 340 | 341 | CODEC_ID_QDMC, |
| 341 | 342 | |
| 342 | 343 | /* subtitle codecs */ |
| 344 | + CODEC_ID_FIRST_SUBTITLE = 0x17000, ///< A dummy ID pointing at the start of subtitle codecs. | |
| 343 | 345 | CODEC_ID_DVD_SUBTITLE= 0x17000, |
| 344 | 346 | CODEC_ID_DVB_SUBTITLE, |
| 345 | 347 | CODEC_ID_TEXT, ///< raw UTF-8 text |
| @@ -351,6 +353,7 @@ enum CodecID { · 5 unmodified lines | ||
| 351 | 353 | CODEC_ID_SRT, |
| 352 | 354 | |
| 353 | 355 | /* other specific kind of codecs (generally used for attachments) */ |
| 356 | + CODEC_ID_FIRST_UNKNOWN = 0x18000, ///< A dummy ID pointing at the start of various fake codecs. | |
| 354 | 357 | CODEC_ID_TTF= 0x18000, |
| 355 | 358 | |
| 356 | 359 | CODEC_ID_PROBE= 0x19000, ///< codec_id is not known (like CODEC_ID_NONE) but lavf should attempt to identify it |
| @@ -4273,4 +4276,9 @@ enum AVLockOp { · 3916 unmodified lines | ||
| 4273 | 4276 | */ |
| 4274 | 4277 | int av_lockmgr_register(int (*cb)(void **mutex, enum AVLockOp op)); |
| 4275 | 4278 | |
| 4279 | +/** | |
| 4280 | + * Get the type of the given codec. | |
| 4281 | + */ | |
| 4282 | +enum AVMediaType avcodec_get_type(enum CodecID codec_id); | |
| 4283 | + | |
| 4276 | 4284 | #endif /* AVCODEC_AVCODEC_H */ |
| @@ -1301,3 +1301,17 @@ int avcodec_thread_init(AVCodecContext *s, int thread_count) · 1300 unmodified lines | ||
| 1301 | 1301 | return ff_thread_init(s); |
| 1302 | 1302 | } |
| 1303 | 1303 | #endif |
| 1304 | + | |
| 1305 | +enum AVMediaType avcodec_get_type(enum CodecID codec_id) | |
| 1306 | +{ | |
| 1307 | + if (codec_id <= CODEC_ID_NONE) | |
| 1308 | + return AVMEDIA_TYPE_UNKNOWN; | |
| 1309 | + else if (codec_id < CODEC_ID_FIRST_AUDIO) | |
| 1310 | + return AVMEDIA_TYPE_VIDEO; | |
| 1311 | + else if (codec_id < CODEC_ID_FIRST_SUBTITLE) | |
| 1312 | + return AVMEDIA_TYPE_AUDIO; | |
| 1313 | + else if (codec_id < CODEC_ID_FIRST_UNKNOWN) | |
| 1314 | + return AVMEDIA_TYPE_SUBTITLE; | |
| 1315 | + | |
| 1316 | + return AVMEDIA_TYPE_UNKNOWN; | |
| 1317 | +} | |
| @@ -21,8 +21,8 @@ · 20 unmodified lines | ||
| 21 | 21 | #define AVCODEC_VERSION_H |
| 22 | 22 | |
| 23 | 23 | #define LIBAVCODEC_VERSION_MAJOR 53 |
| 24 | −#define LIBAVCODEC_VERSION_MINOR 7 | |
| 25 | −#define LIBAVCODEC_VERSION_MICRO 1 | |
| 24 | +#define LIBAVCODEC_VERSION_MINOR 8 | |
| 25 | +#define LIBAVCODEC_VERSION_MICRO 0 | |
| 26 | 26 | |
| 27 | 27 | #define LIBAVCODEC_VERSION_INT AV_VERSION_INT(LIBAVCODEC_VERSION_MAJOR, \ |
| 28 | 28 | LIBAVCODEC_VERSION_MINOR, \ |