avformat/utils: Move av_read_(play|pause) to demux_utils.c

These functions are for demuxers only.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This commit is contained in:
Andreas Rheinhardt 2022-05-06 21:06:03 +02:00
parent f104352b91
commit 0b0dfb765d
2 changed files with 18 additions and 18 deletions

View File

@ -197,3 +197,21 @@ FF_ENABLE_DEPRECATION_WARNINGS
}
return 0;
}
int av_read_play(AVFormatContext *s)
{
if (s->iformat->read_play)
return s->iformat->read_play(s);
if (s->pb)
return avio_pause(s->pb, 0);
return AVERROR(ENOSYS);
}
int av_read_pause(AVFormatContext *s)
{
if (s->iformat->read_pause)
return s->iformat->read_pause(s);
if (s->pb)
return avio_pause(s->pb, 1);
return AVERROR(ENOSYS);
}

View File

@ -458,24 +458,6 @@ int av_find_best_stream(AVFormatContext *ic, enum AVMediaType type,
/*******************************************************/
int av_read_play(AVFormatContext *s)
{
if (s->iformat->read_play)
return s->iformat->read_play(s);
if (s->pb)
return avio_pause(s->pb, 0);
return AVERROR(ENOSYS);
}
int av_read_pause(AVFormatContext *s)
{
if (s->iformat->read_pause)
return s->iformat->read_pause(s);
if (s->pb)
return avio_pause(s->pb, 1);
return AVERROR(ENOSYS);
}
int ff_stream_side_data_copy(AVStream *dst, const AVStream *src)
{
/* Free existing side data*/