# HG changeset patch # User bcoudurier # Date 1258664605 0 # Node ID a0846aa55f5e7a9c64477a05a25bb95289aa2ef0 # Parent 238bda5af58e1970d108fc9f9915ce96b85f20f0 use AVFormatContext in dprintf diff -r 238bda5af58e -r a0846aa55f5e mov.c --- a/mov.c Wed Nov 18 17:15:17 2009 +0000 +++ b/mov.c Thu Nov 19 21:03:25 2009 +0000 @@ -2251,18 +2251,18 @@ return 0; } -static int mov_seek_stream(AVStream *st, int64_t timestamp, int flags) +static int mov_seek_stream(AVFormatContext *s, AVStream *st, int64_t timestamp, int flags) { MOVStreamContext *sc = st->priv_data; int sample, time_sample; int i; sample = av_index_search_timestamp(st, timestamp, flags); - dprintf(st->codec, "stream %d, timestamp %"PRId64", sample %d\n", st->index, timestamp, sample); + dprintf(s, "stream %d, timestamp %"PRId64", sample %d\n", st->index, timestamp, sample); if (sample < 0) /* not sure what to do */ return -1; sc->current_sample = sample; - dprintf(st->codec, "stream %d, found sample %d\n", st->index, sc->current_sample); + dprintf(s, "stream %d, found sample %d\n", st->index, sc->current_sample); /* adjust ctts index */ if (sc->ctts_data) { time_sample = 0; @@ -2292,7 +2292,7 @@ sample_time = 0; st = s->streams[stream_index]; - sample = mov_seek_stream(st, sample_time, flags); + sample = mov_seek_stream(s, st, sample_time, flags); if (sample < 0) return -1; @@ -2305,7 +2305,7 @@ continue; timestamp = av_rescale_q(seek_timestamp, s->streams[stream_index]->time_base, st->time_base); - mov_seek_stream(st, timestamp, flags); + mov_seek_stream(s, st, timestamp, flags); } return 0; }