Logo Search packages:      
Sourcecode: blender version File versions  Download package

static void av_update_cur_dts ( AVFormatContext *  s,
AVStream *  ref_st,
int64_t  timestamp 
) [static]

Updates cur_dts of all streams based on given timestamp and AVStream.

Stream ref_st unchanged, others set cur_dts in their native timebase only needed for timestamp wrapping or if (dts not set and pts!=dts)

Parameters:
timestamp new dts expressed in time_base of param ref_st
ref_st reference stream giving time_base of param timestamp

Definition at line 1122 of file utils.c.

References av_rescale().

Referenced by av_seek_frame_binary().

                                                                                      {
    int i;

    for(i = 0; i < s->nb_streams; i++) {
        AVStream *st = s->streams[i];

        st->cur_dts = av_rescale(timestamp,
                                 st->time_base.den * (int64_t)ref_st->time_base.num,
                                 st->time_base.num * (int64_t)ref_st->time_base.den);
    }
}


Generated by  Doxygen 1.6.0   Back to index