Unified · Split
| @@ -15,6 +15,9 @@ libavutil: 2012-10-22 · 14 unmodified lines | ||
| 15 | 15 | |
| 16 | 16 | API changes, most recent first: |
| 17 | 17 | |
| 18 | +2012-12-15 - xxxxxxx - lavc 54.80.100 - avcodec.h | |
| 19 | + Add pkt_size field to AVFrame. | |
| 20 | + | |
| 18 | 21 | 2012-11-25 - xxxxxxx - lavu 52.9.100 - opt.h |
| 19 | 22 | Add the following convenience functions to opt.h: |
| 20 | 23 | av_opt_get_image_size |
| @@ -1467,6 +1467,16 @@ typedef struct AVFrame { · 1466 unmodified lines | ||
| 1467 | 1467 | * - decoding: Read by user. |
| 1468 | 1468 | */ |
| 1469 | 1469 | int64_t channels; |
| 1470 | + | |
| 1471 | + /** | |
| 1472 | + * size of the corresponding packet containing the compressed | |
| 1473 | + * frame. It must be accessed using av_frame_get_pkt_size() and | |
| 1474 | + * av_frame_set_pkt_size(). | |
| 1475 | + * It is set to a negative value if unknown. | |
| 1476 | + * - encoding: unused | |
| 1477 | + * - decoding: set by libavcodec, read by user. | |
| 1478 | + */ | |
| 1479 | + int pkt_size; | |
| 1470 | 1480 | } AVFrame; |
| 1471 | 1481 | |
| 1472 | 1482 | /** |
| @@ -1490,6 +1500,8 @@ AVDictionary *av_frame_get_metadata (const AVFrame *frame); · 17 unmodified lines | ||
| 1490 | 1500 | void av_frame_set_metadata (AVFrame *frame, AVDictionary *val); |
| 1491 | 1501 | int av_frame_get_decode_error_flags (const AVFrame *frame); |
| 1492 | 1502 | void av_frame_set_decode_error_flags (AVFrame *frame, int val); |
| 1503 | +int av_frame_get_pkt_size(const AVFrame *frame); | |
| 1504 | +void av_frame_set_pkt_size(AVFrame *frame, int val); | |
| 1493 | 1505 | |
| 1494 | 1506 | struct AVCodecInternal; |
| 1495 | 1507 | |
| @@ -248,6 +248,7 @@ const AVClass *avcodec_get_class(void) · 247 unmodified lines | ||
| 248 | 248 | static const AVOption frame_options[]={ |
| 249 | 249 | {"best_effort_timestamp", "", FOFFSET(best_effort_timestamp), AV_OPT_TYPE_INT64, {.i64 = AV_NOPTS_VALUE }, INT64_MIN, INT64_MAX, 0}, |
| 250 | 250 | {"pkt_pos", "", FOFFSET(pkt_pos), AV_OPT_TYPE_INT64, {.i64 = -1 }, INT64_MIN, INT64_MAX, 0}, |
| 251 | +{"pkt_size", "", FOFFSET(pkt_size), AV_OPT_TYPE_INT64, {.i64 = -1 }, INT64_MIN, INT64_MAX, 0}, | |
| 251 | 252 | {"sample_aspect_ratio", "", FOFFSET(sample_aspect_ratio), AV_OPT_TYPE_RATIONAL, {.dbl = 0 }, 0, INT_MAX, 0}, |
| 252 | 253 | {"width", "", FOFFSET(width), AV_OPT_TYPE_INT, {.i64 = 0 }, 0, INT_MAX, 0}, |
| 253 | 254 | {"height", "", FOFFSET(height), AV_OPT_TYPE_INT, {.i64 = 0 }, 0, INT_MAX, 0}, |
| @@ -512,10 +512,12 @@ void ff_init_buffer_info(AVCodecContext *s, AVFrame *frame) · 511 unmodified lines | ||
| 512 | 512 | frame->pkt_pts = s->pkt->pts; |
| 513 | 513 | frame->pkt_pos = s->pkt->pos; |
| 514 | 514 | frame->pkt_duration = s->pkt->duration; |
| 515 | + frame->pkt_size = s->pkt->size; | |
| 515 | 516 | } else { |
| 516 | 517 | frame->pkt_pts = AV_NOPTS_VALUE; |
| 517 | 518 | frame->pkt_pos = -1; |
| 518 | 519 | frame->pkt_duration = 0; |
| 520 | + frame->pkt_size = -1; | |
| 519 | 521 | } |
| 520 | 522 | frame->reordered_opaque = s->reordered_opaque; |
| 521 | 523 | |
| @@ -677,6 +679,7 @@ void avcodec_get_frame_defaults(AVFrame *frame) · 155 unmodified lines | ||
| 677 | 679 | frame->best_effort_timestamp = AV_NOPTS_VALUE; |
| 678 | 680 | frame->pkt_duration = 0; |
| 679 | 681 | frame->pkt_pos = -1; |
| 682 | + frame->pkt_size = -1; | |
| 680 | 683 | frame->key_frame = 1; |
| 681 | 684 | frame->sample_aspect_ratio = (AVRational) {0, 1 }; |
| 682 | 685 | frame->format = -1; /* unknown */ |
| @@ -723,6 +726,7 @@ MAKE_ACCESSORS(AVFrame, frame, int, channels) · 40 unmodified lines | ||
| 723 | 726 | MAKE_ACCESSORS(AVFrame, frame, int, sample_rate) |
| 724 | 727 | MAKE_ACCESSORS(AVFrame, frame, AVDictionary *, metadata) |
| 725 | 728 | MAKE_ACCESSORS(AVFrame, frame, int, decode_error_flags) |
| 729 | +MAKE_ACCESSORS(AVFrame, frame, int, pkt_size) | |
| 726 | 730 | |
| 727 | 731 | MAKE_ACCESSORS(AVCodecContext, codec, AVRational, pkt_timebase) |
| 728 | 732 | MAKE_ACCESSORS(AVCodecContext, codec, const AVCodecDescriptor *, codec_descriptor) |
| @@ -29,8 +29,8 @@ · 28 unmodified lines | ||
| 29 | 29 | #include "libavutil/avutil.h" |
| 30 | 30 | |
| 31 | 31 | #define LIBAVCODEC_VERSION_MAJOR 54 |
| 32 | −#define LIBAVCODEC_VERSION_MINOR 79 | |
| 33 | −#define LIBAVCODEC_VERSION_MICRO 102 | |
| 32 | +#define LIBAVCODEC_VERSION_MINOR 80 | |
| 33 | +#define LIBAVCODEC_VERSION_MICRO 100 | |
| 34 | 34 | |
| 35 | 35 | #define LIBAVCODEC_VERSION_INT AV_VERSION_INT(LIBAVCODEC_VERSION_MAJOR, \ |
| 36 | 36 | LIBAVCODEC_VERSION_MINOR, \ |