CPU : Davinci DM6467
DSP: BIOS 5.41
OS : Linux 2.6.32
DVSDK: 3.10.0.16
For achieving Audio Video Synchronization, we need to render both Audio and Video frames using their respective Presentation Time Stamps (PTS).
In case of video, it is possible that the encoded frames are transmitted in a different sequence as compared to the rendering (example - future frames used for reconstruction of B-frames). In such a case, it becomes important that the PTS should be used to accurately determine the presentation time of the raw Video.
We have extracted the PCR(Program Clock Reference) from the incoming transport stream to drive a hardware counter which would be used as a referece for compparison with the PTS.
Presently the decoder accepts only the encoded data (payload of the TS packet) and not the PTS (which is contained in the adaptation field). Therefore associating the PTS with the decoded (raw) data becomes difficult since the PTS received in the encoded transport stream cannot accurately be applied to the decoded frames (especially in the case mentioned above).
We are using the folllowing version od decoders
Video decoders:
1) Mpeg2 decoder : 1.10.0.10
2) H264 decoder : 1.10.4.0
Audio Decoders
1) Mp3 decoder : 1.31.1.1
2) AAC decoder : 1.30.1.0
Is there a way to correctly associate the PTS received in the transport stream to the raw Video frames in the correct order? Would it help if the decoder could accept the PTS (adaption field) and output them along with raw data for maintaining accuracy when rendering Video frames?