Revision 3ba1438d libavformat/avformat.h

View differences:

libavformat/avformat.h
5 5
extern "C" {
6 6
#endif
7 7

  
8
#define LIBAVFORMAT_BUILD       4618
8
#define LIBAVFORMAT_BUILD       4619
9 9

  
10 10
#define LIBAVFORMAT_VERSION_INT FFMPEG_VERSION_INT
11 11
#define LIBAVFORMAT_VERSION     FFMPEG_VERSION
......
165 165
    /* close the stream. The AVFormatContext and AVStreams are not
166 166
       freed by this function */
167 167
    int (*read_close)(struct AVFormatContext *);
168
    /* seek at or before a given timestamp (given in AV_TIME_BASE
169
       units) relative to the frames in stream component stream_index */
168
    /** 
169
     * seek to a given timestamp relative to the frames in 
170
     * stream component stream_index
171
     * @param stream_index must not be -1
172
     * @param flags selects which direction should be preferred if no exact 
173
     *              match is available
174
     */
170 175
    int (*read_seek)(struct AVFormatContext *, 
171
                     int stream_index, int64_t timestamp);
176
                     int stream_index, int64_t timestamp, int flags);
172 177
    /**
173 178
     * gets the next timestamp in AV_TIME_BASE units.
174 179
     */
......
553 558
int av_find_stream_info(AVFormatContext *ic);
554 559
int av_read_packet(AVFormatContext *s, AVPacket *pkt);
555 560
int av_read_frame(AVFormatContext *s, AVPacket *pkt);
556
int av_seek_frame(AVFormatContext *s, int stream_index, int64_t timestamp);
561
int av_seek_frame(AVFormatContext *s, int stream_index, int64_t timestamp, int flags);
557 562
int av_read_play(AVFormatContext *s);
558 563
int av_read_pause(AVFormatContext *s);
559 564
void av_close_input_file(AVFormatContext *s);
......
561 566
void av_set_pts_info(AVStream *s, int pts_wrap_bits,
562 567
                     int pts_num, int pts_den);
563 568

  
569
#define AVSEEK_FLAG_BACKWARD 1 ///< seek backward
570
#define AVSEEK_FLAG_BYTE     2 ///< seeking based on position in bytes
571

  
564 572
int av_find_default_stream_index(AVFormatContext *s);
565
int av_index_search_timestamp(AVStream *st, int timestamp);
573
int av_index_search_timestamp(AVStream *st, int timestamp, int flags);
566 574
int av_add_index_entry(AVStream *st,
567 575
                       int64_t pos, int64_t timestamp, int distance, int flags);
568
int av_seek_frame_binary(AVFormatContext *s, int stream_index, int64_t target_ts);
576
int av_seek_frame_binary(AVFormatContext *s, int stream_index, int64_t target_ts, int flags);
569 577

  
570 578
/* media file output */
571 579
int av_set_parameters(AVFormatContext *s, AVFormatParameters *ap);

Also available in: Unified diff