diff options
author | Clément Bœsch <ubitux@gmail.com> | 2013-03-10 00:34:16 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2013-03-10 01:25:02 +0100 |
commit | 586ae70ba78e023d16c0c812b05a26c7d423833b (patch) | |
tree | 133135d3a94d2467cb1b49c83057a8397c078571 /libavutil/frame.c | |
parent | d1b456b0a80a92f8fd96adb244d4697addf319bd (diff) | |
download | ffmpeg-streaming-586ae70ba78e023d16c0c812b05a26c7d423833b.zip ffmpeg-streaming-586ae70ba78e023d16c0c812b05a26c7d423833b.tar.gz |
port FFmpeg lavc frame specificities to lavu functions.
Diffstat (limited to 'libavutil/frame.c')
-rw-r--r-- | libavutil/frame.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/libavutil/frame.c b/libavutil/frame.c index 2e2393d..11c0aa1 100644 --- a/libavutil/frame.c +++ b/libavutil/frame.c @@ -49,7 +49,13 @@ static void get_frame_defaults(AVFrame *frame) memset(frame, 0, sizeof(*frame)); - frame->pts = AV_NOPTS_VALUE; + frame->pts = + frame->pkt_dts = + frame->pkt_pts = AV_NOPTS_VALUE; + av_frame_set_best_effort_timestamp(frame, AV_NOPTS_VALUE); + av_frame_set_pkt_duration (frame, 0); + av_frame_set_pkt_pos (frame, -1); + av_frame_set_pkt_size (frame, -1); frame->key_frame = 1; frame->sample_aspect_ratio = (AVRational){ 0, 1 }; frame->format = -1; /* unknown */ @@ -63,6 +69,7 @@ AVFrame *av_frame_alloc(void) if (!frame) return NULL; + frame->extended_data = NULL; get_frame_defaults(frame); return frame; |