Results 1 to 8 of 8

Thread: mp4 recorded live streams: audio gets out of sync

  1. #1
    Join Date
    May 2012
    Posts
    18

    Default mp4 recorded live streams: audio gets out of sync

    I'm using the developer version with Wirecast.
    To record the live stream I'm using the "record-live" StreamType and use the mp4: prefix.

    The audio in the recorded mp4s gets completely out of sync.
    I didn't try it yet without the mp4: prefix but I've recorded the raw live stream with rtmpdump and it doesn't have any issues as suspected.

    This is the media info of the server side recording:
    http://pastebin.com/DSL2sTvK

    This is the media info of the raw recording:
    http://pastebin.com/TdtA0qi9

    My guess is that Wowza doesn't regard the variable frame rate when muxing the streams into the mp4 container.

    I'm not sure if the sync issues also happen with the default server side recording. Gonna have to try it out.

    Regards

  2. #2
    Join Date
    Dec 2007
    Posts
    28,381

    Default

    This is generally a problem with the source, the encoder. You can enable this Property so you can debug alignment:

    http://www.wowza.com/forums/content....-packetization

    Richard

  3. #3
    Join Date
    May 2012
    Posts
    18

    Default

    Thank you Richard!
    I'm gonna try it out.

    Anyway, if the problem is the source then why doesn't the sync issues arise with the live stream and the local recording?

  4. #4
    Join Date
    May 2012
    Posts
    18

    Default

    Hi Richard,

    I've added the debug properties and this is the output:
    http://pastebin.com/L6gpGewH

    There are two Timecode out of order warning for SanJose and Cupertino.

    I've done a stream now with the mp4: prefix removed and Wowza created a perfectly working flv video without any sync issues.

    So the default flv recording works. The mp4 recording does not.

  5. #5
    Join Date
    Dec 2007
    Posts
    28,381

    Default

    I don't see output of the debug property in that log snip. It looks like this:
    Code:
    tc[difference]: [calculatedTimecode]:[packetTimecode]:[sampleRate]
    Be sure to add "cupertinostreamingpacketizer" to /Streams /LiveStreamPacketizers

    Can you clarify what you mean by out of sync? How out of sync? Does it drift out of sync over time and is back in sync if you stop playing and start again? What player are using to playback the stream? Is the stream out of sync when played back using Wowza Server?

    What is the key frame interval set to? If it is very long that might be a problem. Try adding this Property to the Application.xml /Streams /Properties list:

    Code:
    <Property>
    <Name>recordWaitForVideoKeyFrame</Name>
    <Value>true</Value>
    <Type>Boolean</Type>
    </Property>
    Richard

  6. #6
    Join Date
    May 2012
    Posts
    18

    Default

    Hi & thanks again for your reply!

    I did add the following lines to Streams/Properties:
    Code:
    <Property>
    	<Name>debugAACTimecodes</Name>
    	<Value>true</Value>
    	<Type>Boolean</Type>
    </Property>
    But the output doesn't show any line starting with "tc".

    Be sure to add "cupertinostreamingpacketizer" to /Streams /LiveStreamPacketizers
    This is already added by default.

    Can you clarify what you mean by out of sync? How out of sync? Does it drift out of sync over time and is back in sync if you stop playing and start again? What player are using to playback the stream? Is the stream out of sync when played back using Wowza Server?
    The audio and video drifts out of sync over time. When I jump to to end of the video the delay is much higher.
    I have this issue with PotPlayer and Media Player Classic - HC. VLC seems to play the videos fine.
    I've just tried JWPlayer through the VOD application and couldn't observe any sync issues.

    What is the key frame interval set to? If it is very long that might be a problem. Try adding this Property to the Application.xml /Streams /Properties list:
    The keyframe interval is set to every 8 seconds. It's the default setting. I think this should be fine since I'm not using SanJose.

    Adding the "recordWaitForVideoKeyFrame" property seems to solve the sync problem for the standalone players.
    Can it be problematic to simply leave this setting?

    Thanks & regards,
    Philipp

  7. #7
    Join Date
    Aug 2010
    Posts
    13

    Default

    Did anyone ever figure out a solution to this or what to look for in the logs? For instance if there are timecode errors that show up what can be done about it?

  8. #8
    Join Date
    Dec 2007
    Posts
    28,381

    Default

    Try different settings in the encoder. Yesterday another user found that changing to 24fps video fixed audio sync issue. We don't think that is a fix-all in other situations necessarily, but changing audio and video details is where I would start.

    Richard

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •