AVStream Struct Reference

Stream structure. More...

#include <avformat.h>


Data Fields

int index
 stream index in AVFormatContext
int id
 format-specific stream ID
AVCodecContextcodec
 codec context
AVRational r_frame_rate
 Real base framerate of the stream.
void * priv_data
int64_t first_dts
struct AVFrac pts
 encoding: pts generation when outputting stream
AVRational time_base
 This is the fundamental unit of time (in seconds) in terms of which frame timestamps are represented.
int pts_wrap_bits
 number of bits in pts (used for wrapping control)
int stream_copy
 If set, just copy stream.
enum AVDiscard discard
 Selects which packets can be discarded at will and do not need to be demuxed.
float quality
 Quality, as it has been removed from AVCodecContext and put in AVVideoFrame.
int64_t start_time
 Decoding: pts of the first frame of the stream, in stream time base.
int64_t duration
 Decoding: duration of the stream, in stream time base.
char language [4]
enum AVStreamParseType need_parsing
 ISO 639 3-letter language code (empty string if undefined).
struct AVCodecParserContextparser
int64_t cur_dts
int last_IP_duration
int64_t last_IP_pts
AVIndexEntryindex_entries
 Only used if the format does not support seeking natively.
int nb_index_entries
unsigned int index_entries_allocated_size
int64_t nb_frames
 number of frames in this stream if known or 0
int64_t unused [4+1]
char * filename
 source filename of the stream
int disposition
 AV_DISPOSITION_* bit field.
AVProbeData probe_data
int64_t pts_buffer [MAX_REORDER_DELAY+1]
AVRational sample_aspect_ratio
 sample aspect ratio (0 if unknown)
  • encoding: Set by user.

AVMetadatametadata
const uint8_t * cur_ptr
int cur_len
AVPacket cur_pkt
int64_t reference_dts
 Timestamp corresponding to the last dts sync point.


Detailed Description

Stream structure.

New fields can be added to the end with minor version bumps. Removal, reordering and changes to existing fields require a major version bump. sizeof(AVStream) must not be used outside libav*.

Definition at line 428 of file avformat.h.


Field Documentation

codec context

Definition at line 431 of file avformat.h.

Referenced by add_audio_stream(), add_av_stream(), add_av_stream1(), add_codec(), add_dstream(), add_video_stream(), adts_write_header(), aiff_read_header(), aiff_read_packet(), alloc_picture(), amf_parse_object(), amr_read_header(), amr_read_packet(), apc_read_header(), ape_read_header(), asf_read_close(), asf_read_header(), asf_write_header1(), asf_write_packet(), au_read_header(), audio_decode_frame(), audio_read_header(), audio_read_packet(), audio_write_header(), av_close_input_stream(), av_encode(), av_estimate_timings_from_bit_rate(), av_exit(), av_find_default_stream_index(), av_find_stream_info(), av_interleaved_write_frame(), av_new_stream(), av_open_input_stream(), av_read_frame_internal(), av_read_packet(), av_write_header(), avi_read_close(), avi_read_header(), avi_read_packet(), avi_write_counters(), avi_write_header(), avi_write_idx1(), avi_write_ix(), avi_write_packet(), avi_write_trailer(), avisynth_read_header(), avs_read_packet(), bfi_read_header(), build_feed_streams(), build_file_streams(), build_frame_code(), cdata_read_header(), check_audio_video_sub_inputs(), cin_read_header(), close_audio(), close_connection(), close_video(), compute_bandwidth(), compute_frame_duration(), compute_pkt_fields(), compute_pkt_fields2(), compute_status(), create_audio_stream(), create_stream(), daud_header(), daud_write_header(), dc1394_read_common(), decode_stream_header(), decode_thread(), do_audio_out(), do_subtitle_out(), do_video_out(), do_video_stats(), dump_stream_format(), dv_assemble_frame(), dv_extract_audio_info(), dv_extract_video_info(), dv_frame_offset(), dv_init_demux(), dv_init_mux(), dv_offset_reset(), dv_produce_packet(), dxa_read_header(), ea_read_header(), extract_mpeg4_header(), ff_asf_parse_packet(), ff_audio_interleave_close(), ff_audio_interleave_init(), ff_audio_rechunk_interleave(), ff_rm_parse_packet(), ff_rm_read_mdpr_codecdata(), ff_rm_retrieve_cache(), ff_rtp_send_aac(), ffm_read_header(), ffm_write_header(), film_read_header(), find_stream_in_feed(), flac_header(), flac_read_header(), flac_write_header(), flac_write_trailer(), flic_read_header(), flv_get_extradata(), flv_read_metabody(), flv_read_packet(), flv_set_audio_codec(), flv_set_video_codec(), flv_write_header(), flv_write_packet(), fourxm_read_header(), get_audio_clock(), get_codec_data(), get_sindex(), get_watermark_picture(), gif_write_header(), gif_write_packet(), grab_read_header(), gxf_packet(), gxf_write_header(), gxf_write_umf_track_description(), http_prepare_data(), http_receive_data(), idcin_read_header(), iff_read_header(), iff_read_packet(), img_read_header(), img_read_packet(), ipmovie_read_header(), iss_read_header(), iss_read_packet(), lmlm4_read_header(), main(), matroska_parse_block(), matroska_read_header(), mkv_write_block(), mkv_write_header(), mkv_write_packet(), mkv_write_tracks(), mkv_write_trailer(), mm_read_header(), mmf_read_header(), modify_current_stream(), mov_build_index(), mov_read_close(), mov_read_ctts(), mov_read_enda(), mov_read_esds(), mov_read_extradata(), mov_read_glbl(), mov_read_hdlr(), mov_read_smi(), mov_read_stsd(), mov_read_trak(), mov_read_trun(), mov_read_wave(), mov_seek_stream(), mov_write_ftyp_tag(), mov_write_header(), mov_write_uuidprof_tag(), mp3_read_header(), mpc8_read_header(), mpc_read_header(), mpeg_mux_init(), mpeg_mux_write_packet(), mpegps_read_packet(), mpegts_read_header(), mpegts_write_header(), mpegts_write_packet(), mpegts_write_pes(), mpegts_write_pmt(), msnwc_tcp_read_header(), mtv_read_header(), mxf_get_d10_aes3_packet(), mxf_parse_mpeg2_frame(), mxf_parse_structural_metadata(), mxf_write_cdci_common(), mxf_write_common_fields(), mxf_write_d10_audio_packet(), mxf_write_d10_video_packet(), mxf_write_generic_sound_common(), mxf_write_header(), mxf_write_identification(), mxf_write_mpegvideo_desc(), mxf_write_packet(), mxf_write_wav_common(), nc_read_header(), new_audio_stream(), new_pes_av_stream(), new_subtitle_stream(), new_video_stream(), nsv_parse_NSVs_header(), nsv_read_chunk(), nsv_read_close(), nut_read_header(), nuv_header(), ogg_write_header(), ogg_write_packet(), ogg_write_trailer(), ogm_dshow_header(), ogm_header(), old_flac_header(), oma_read_header(), oma_read_packet(), open_audio(), open_input_stream(), open_parser(), open_video(), opt_input_file(), opt_target(), output_packet(), output_picture2(), parse_h264_sdp_line(), pmt_cb(), pre_process_video_frame(), prepare_sdp_description(), print_report(), pva_read_header(), queue_picture(), r3d_read_rdvo(), r3d_read_red1(), r3d_read_reda(), r3d_read_redv(), r3d_seek(), rdt_parse_packet(), rdt_parse_sdp_line(), read_ffserver_streams(), read_header(), read_packet(), real_parse_asm_rule(), rl2_read_header(), rm_ac3_swap_bytes(), rm_read_audio_stream_info(), rm_read_dts(), rm_read_header(), rm_read_packet(), rm_write_header(), rm_write_packet(), roq_read_header(), rpl_read_header(), rpl_read_packet(), rtp_new_av_stream(), rtp_parse_open(), rtp_parse_packet(), rtp_write_header(), rtp_write_packet(), sdp_parse_fmtp(), sdp_parse_fmtp_config_h264(), sdp_parse_line(), seq_read_header(), set_codec_from_probe_data(), siff_parse_vbv1(), smacker_read_header(), sol_read_header(), speex_header(), str_read_packet(), stream_component_close(), stream_component_open(), stream_cycle_channel(), stream_index_from_inputs(), subtitle_thread(), swf_read_packet(), swf_write_header(), swf_write_packet(), swf_write_trailer(), synchronize_audio(), theora_header(), thp_read_header(), try_decode_frame(), tta_read_header(), txd_read_header(), update_initial_durations(), update_sample_display(), v4l2_read_header(), v4l2_read_packet(), vc1t_read_header(), vc1test_write_header(), vfw_read_header(), vid_read_header(), vid_read_packet(), video_audio_display(), video_image_display(), video_open(), video_thread(), vmd_read_header(), voc_get_packet(), voc_read_header(), voc_write_header(), voc_write_packet(), vorbis_header(), wav_read_header(), wav_read_packet(), wav_read_seek(), wc3_read_header(), write_audio_frame(), write_globalinfo(), write_header(), write_streamheader(), write_trailer(), write_video_frame(), wsaud_read_header(), wsvqa_read_header(), wv_read_header(), x11grab_read_header(), xa_read_header(), xa_read_packet(), yuv4_read_header(), and yuv4_read_packet().

Definition at line 520 of file avformat.h.

Referenced by av_read_frame_flush(), and av_read_frame_internal().

const uint8_t* AVStream::cur_ptr

Definition at line 519 of file avformat.h.

Referenced by av_read_frame_flush(), and av_read_frame_internal().

AV_DISPOSITION_* bit field.

Definition at line 503 of file avformat.h.

Referenced by av_encode(), matroska_read_header(), mkv_write_tracks(), set_disposition_bits(), and write_streaminfo().

source filename of the stream

Definition at line 500 of file avformat.h.

Referenced by av_close_input_stream(), and ff_metadata_demux_compat().

Definition at line 493 of file avformat.h.

Referenced by av_add_index_entry().

Definition at line 479 of file avformat.h.

Referenced by ff_metadata_demux_compat().

Definition at line 487 of file avformat.h.

Referenced by compute_pkt_fields().

number of frames in this stream if known or 0

Definition at line 495 of file avformat.h.

Referenced by aiff_read_header(), ape_read_header(), avs_read_packet(), mkv_write_ass_blocks(), mov_build_index(), mov_read_stts(), and read_header().

Definition at line 441 of file avformat.h.

Referenced by add_av_stream1(), add_dstream(), asf_read_header(), asf_read_pts(), asf_reset_header(), av_close_input_stream(), av_open_input_stream(), av_write_trailer(), avi_read_header(), avi_read_idx1(), avi_read_packet(), avi_read_seek(), clean_index(), compute_status(), ff_asf_parse_packet(), ff_audio_interleave_close(), ff_audio_interleave_init(), ff_audio_rechunk_interleave(), ff_interleave_new_audio_packet(), ff_rdt_parse_close(), ff_rdt_parse_open(), flush_packet(), get_system_header_size(), gxf_write_header(), gxf_write_media_packet(), gxf_write_media_preamble(), gxf_write_track_description_section(), gxf_write_umf_media_description(), gxf_write_umf_track_description(), http_prepare_data(), mov_build_index(), mov_read_close(), mov_read_ctts(), mov_read_dref(), mov_read_elst(), mov_read_mdhd(), mov_read_packet(), mov_read_stco(), mov_read_stsc(), mov_read_stsd(), mov_read_stss(), mov_read_stsz(), mov_read_stts(), mov_read_tkhd(), mov_read_trak(), mov_read_trun(), mov_seek_stream(), mpeg_mux_end(), mpeg_mux_init(), mpeg_mux_write_packet(), mpegts_get_pcr(), mpegts_write_end(), mpegts_write_header(), mpegts_write_packet(), mpegts_write_pes(), mpegts_write_pmt(), mxf_compare_timestamps(), mxf_free(), mxf_get_stream_index(), mxf_parse_mpeg2_frame(), mxf_parse_structural_metadata(), mxf_write_cdci_common(), mxf_write_essence_container_refs(), mxf_write_footer(), mxf_write_generic_desc(), mxf_write_header(), mxf_write_index_table_segment(), mxf_write_multi_descriptor(), mxf_write_package(), mxf_write_packet(), mxf_write_system_item(), mxf_write_track(), new_pes_av_stream(), nsv_parse_NSVs_header(), nsv_read_chunk(), nsv_read_close(), ogg_interleave_per_granule(), ogg_write_header(), ogg_write_packet(), ogg_write_page(), ogg_write_trailer(), output_packet(), put_system_header(), rdt_parse_sdp_line(), read_braindead_odml_indx(), remove_decoded_packets(), rm_read_close(), rm_read_header(), rm_read_header_old(), rm_read_packet(), rtp_new_av_stream(), rtsp_read_packet(), sdp_parse_fmtp(), and sdp_parse_line().

Definition at line 505 of file avformat.h.

Referenced by av_read_packet().

struct AVFrac AVStream::pts [read]

encoding: pts generation when outputting stream

Definition at line 446 of file avformat.h.

Referenced by av_encode(), av_write_header(), compute_pkt_fields2(), main(), output_packet(), and print_report().

int64_t AVStream::pts_buffer[MAX_REORDER_DELAY+1]

Definition at line 507 of file avformat.h.

Referenced by av_new_stream(), compute_pkt_fields(), and compute_pkt_fields2().

number of bits in pts (used for wrapping control)

Definition at line 454 of file avformat.h.

Referenced by av_set_pts_info(), and compute_pkt_fields().

Quality, as it has been removed from AVCodecContext and put in AVVideoFrame.

MN: dunno if that is the right place for it

Definition at line 461 of file avformat.h.

Referenced by do_video_out(), ffm_read_header(), ffm_write_header(), new_audio_stream(), new_video_stream(), and output_packet().

Real base framerate of the stream.

This is the lowest framerate with which all timestamps can be represented accurately (it is the least common multiple of all framerates in the stream). Note, this value is just a guess! For example, if the time base is 1/90000 and all frames have either approximately 3600 or 1800 timer ticks, then r_frame_rate will be 50/1.

Definition at line 440 of file avformat.h.

Referenced by av_find_stream_info(), avisynth_read_header(), dump_stream_format(), flv_write_header(), nuv_header(), opt_input_file(), and vc1test_write_header().

Timestamp corresponding to the last dts sync point.

Initialized when AVCodecParserContext.dts_sync_point >= 0 and a DTS is received from the underlying container. Otherwise set to AV_NOPTS_VALUE by default.

Definition at line 531 of file avformat.h.

Referenced by av_new_stream(), av_read_frame_flush(), and compute_pkt_fields().

Decoding: pts of the first frame of the stream, in stream time base.

Only set this if you are absolutely 100% sure that the value you set it to really is the pts of the first frame. This may be undefined (AV_NOPTS_VALUE).

Note:
The ASF header does NOT contain a correct start_time the ASF demuxer must NOT set this.

Definition at line 470 of file avformat.h.

Referenced by aiff_read_header(), av_estimate_timings(), av_estimate_timings_from_pts(), av_new_stream(), av_update_stream_timings(), avi_read_header(), avisynth_read_header(), dv_extract_audio_info(), dv_init_demux(), fill_all_stream_timings(), gxf_header(), gxf_seek(), http_prepare_data(), img_read_header(), matroska_read_header(), mp3_read_header(), mpegts_read_header(), mxf_parse_structural_metadata(), nsv_parse_NSVs_header(), nut_read_header(), oma_read_header(), read_header(), rm_read_header(), tta_read_header(), and update_initial_timestamps().

If set, just copy stream.

Definition at line 456 of file avformat.h.

Referenced by av_encode(), new_audio_stream(), new_subtitle_stream(), new_video_stream(), print_report(), and read_ffserver_streams().

int64_t AVStream::unused[4+1]

Definition at line 498 of file avformat.h.


The documentation for this struct was generated from the following file:

Generated on Fri Oct 26 02:35:47 2012 for FFmpeg by  doxygen 1.5.8