Originally committed as revision 25273 to svn://svn.ffmpeg.org/ffmpeg/trunk
Unified · Split
| @@ -63,6 +63,9 @@ · 62 unmodified lines | |||
| 63 | #ifndef FF_API_VIDEO_OLD | 63 | #ifndef FF_API_VIDEO_OLD |
| 64 | #define FF_API_VIDEO_OLD (LIBAVCODEC_VERSION_MAJOR < 53) | 64 | #define FF_API_VIDEO_OLD (LIBAVCODEC_VERSION_MAJOR < 53) |
| 65 | #endif | 65 | #endif |
| 66 | #ifndef FF_API_SUBTITLE_OLD | ||
| 67 | #define FF_API_SUBTITLE_OLD (LIBAVCODEC_VERSION_MAJOR < 53) | ||
| 68 | #endif | ||
| 66 | 69 | ||
| 67 | #define AV_NOPTS_VALUE INT64_C(0x8000000000000000) | 70 | #define AV_NOPTS_VALUE INT64_C(0x8000000000000000) |
| 68 | #define AV_TIME_BASE 1000000 | 71 | #define AV_TIME_BASE 1000000 |
| @@ -3590,7 +3593,7 @@ int avcodec_decode_video2(AVCodecContext *avctx, AVFrame *picture, · 3521 unmodified lines | |||
| 3590 | int *got_picture_ptr, | 3593 | int *got_picture_ptr, |
| 3591 | AVPacket *avpkt); | 3594 | AVPacket *avpkt); |
| 3592 | 3595 | ||
| 3593 | #if LIBAVCODEC_VERSION_MAJOR < 53 | 3596 | #if FF_API_SUBTITLE_OLD |
| 3594 | /* Decode a subtitle message. Return -1 if error, otherwise return the | 3597 | /* Decode a subtitle message. Return -1 if error, otherwise return the |
| 3595 | * number of bytes used. If no subtitle could be decompressed, | 3598 | * number of bytes used. If no subtitle could be decompressed, |
| 3596 | * got_sub_ptr is zero. Otherwise, the subtitle is stored in *sub. */ | 3599 | * got_sub_ptr is zero. Otherwise, the subtitle is stored in *sub. */ |
| @@ -671,7 +671,7 @@ int attribute_align_arg avcodec_decode_audio3(AVCodecContext *avctx, int16_t *sa · 670 unmodified lines | |||
| 671 | return ret; | 671 | return ret; |
| 672 | } | 672 | } |
| 673 | 673 | ||
| 674 | #if LIBAVCODEC_VERSION_MAJOR < 53 | 674 | #if FF_API_SUBTITLE_OLD |
| 675 | int avcodec_decode_subtitle(AVCodecContext *avctx, AVSubtitle *sub, | 675 | int avcodec_decode_subtitle(AVCodecContext *avctx, AVSubtitle *sub, |
| 676 | int *got_sub_ptr, | 676 | int *got_sub_ptr, |
| 677 | const uint8_t *buf, int buf_size) | 677 | const uint8_t *buf, int buf_size) |