[Live-devel] How to synchronize audio and video[already read FAQ]

Shixin Zeng shixinzeng at gmail.com
Sun Jul 31 12:43:57 PDT 2005


Hello, all 
I've read the FAQ about synchronization. It says that the parameter 
presentationTime passed to afterGetFrame() can be used to synchronize, but I 
can't figure out how to use the parameter. I even can't understand the exact 
mean of the parameter. Is it the same as the MediaSource::fPresentationTime 
exactly? In other words, if in my MultiFramedMediaSource::doGetNextFrame() 
implementation, I set fPresentationTime={1000,1000} for one particular 
frame, the receiver should get a presentationTime={1000,1000} for this frame 
when call afterGettingFrame, shouldn't it? 

Another attribute of MediaSource I don't understand is 
fDurationInMicroseconds. In the above example, I set it to 10000 in 
MultiFramedMediaSource::doGetNextFrame, but I always get a 0 for 
durantiontimeInMicroseconds in afterGetttingFrame(), why? 

Thanks in advance 


-- 
Best regards

Shixin Zeng
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.live.com/pipermail/live-devel/attachments/20050731/ee5ed28e/attachment.html


More information about the live-devel mailing list