The RTP timestamp is calculated at clock rate to represent the time.
RTP timestamp represents the time per frame, since one frame (such as I-frame) may be divided into multiple RTP packets, so that multiple RTP timestamp of the same frame are equal. (The frame can be distinguished by the last RTP marker flag per frame, but the most reliable method is to view the same RTP timestamp package as the same frame.) )
Increment of RTP timestamp between two frames = clock frequency/frame rate
Where the clock frequency can be obtained from the SDP, such as:
M=video 2834 RTP/AVP 96
a=rtpmap:96 h264/90000
Its clock frequency is 90000 (usually the clock frequency of the video), if the video frame rate is 25fps, then the RTP timestamp increment value between adjacent frames = 90000/25 = 3600.
In addition, usually the audio clock frequency is generally 8000.
The calculation relationship between RTP timestamp and the playback time NPT can be found in how to calculate the NPT time by RTP timestamp during RTSP playback (http://blog.csdn.net/jasonhwang/article/details/7316168).