summaryrefslogtreecommitdiff
path: root/libavformat/utils.c
diff options
context:
space:
mode:
Diffstat (limited to 'libavformat/utils.c')
-rw-r--r--libavformat/utils.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/libavformat/utils.c b/libavformat/utils.c
index 29eaf1b15a..10e79eb4da 100644
--- a/libavformat/utils.c
+++ b/libavformat/utils.c
@@ -2739,7 +2739,7 @@ AVStream *avformat_new_stream(AVFormatContext *s, AVCodec *c)
st->probe_packets = MAX_PROBE_PACKETS;
/* default pts setting is MPEG-like */
- av_set_pts_info(st, 33, 1, 90000);
+ avpriv_set_pts_info(st, 33, 1, 90000);
st->last_IP_pts = AV_NOPTS_VALUE;
for(i=0; i<MAX_REORDER_DELAY+1; i++)
st->pts_buffer[i]= AV_NOPTS_VALUE;
@@ -3742,9 +3742,17 @@ int ff_hex_to_data(uint8_t *data, const char *p)
return len;
}
+#if FF_API_SET_PTS_INFO
void av_set_pts_info(AVStream *s, int pts_wrap_bits,
unsigned int pts_num, unsigned int pts_den)
{
+ avpriv_set_pts_info(s, pts_wrap_bits, pts_num, pts_den);
+}
+#endif
+
+void avpriv_set_pts_info(AVStream *s, int pts_wrap_bits,
+ unsigned int pts_num, unsigned int pts_den)
+{
AVRational new_tb;
if(av_reduce(&new_tb.num, &new_tb.den, pts_num, pts_den, INT_MAX)){
if(new_tb.num != pts_num)