Click here to Skip to main content
15,886,776 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi There

I am trying to understand the pts value in an audio encoded packet in ffmpeg.

I checked my timebase to be 1/44100

and some pts values : 70754080000, 70759090000, back to back packet pts values.

I dont know how to convert that to real time. I would imagine it having something to do with the time base.

I an se that the packets seem to be coming in every half a second, but not sure how that equates to the numbers provided.

Any help would be greatly appreciated.
Posted

1 solution

read the avformat.h there stands:

/* AVPacket.pts, AVPacket.dts and AVPacket.duration timing information will be
 * set if known. They may also be unset (i.e. AV_NOPTS_VALUE for
 * pts/dts, 0 for duration) if the stream does not provide them. The timing
 * information will be in AVStream.time_base units, i.e. it has to be
 * multiplied by the timebase to convert them to seconds.*/


it are timestamps from the stream.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900