OT Mux, Remux, Demux, Sync - relationship?

TeetimeNC wrote on 5/8/2014, 6:23 AM
I have an associate who receives h.264 from various clients, and then renders it with title and minor cuts to wmv. In 95% of the cases this works without problem. In 5% of the time there is an audio-video sync issue. Specifically the sync drifts further apart as the one hour video progresses. The out-of-sync is there on the timeline before render. My questions are:

1. What can cause this out-of-sync?

2. Is this something we should be able to fix with demux/remux? What is it that remux actually does?

3. Is there something else we should be looking at?

/jerry

Comments

DeadRadioStar wrote on 5/8/2014, 11:15 AM
h.264 is video only -- where is the audio coming from? You say the sync difference is already evident on the timeline, so are you importing the video, then the audio from a separate file?

If the audio was recorded on a device separate to the video, then the sync drift could be caused by the clocks (word clock/sample rate) of the devices differing.
TeetimeNC wrote on 5/9/2014, 6:43 AM
Yes, our h264 does contain both video and audio.

/jerry
Rob Franks wrote on 5/9/2014, 8:26 AM
h.264 does not contain audio. It is a video compression standard. An h.264 video stream is housed in a container of some kind (MP4... TS... M2TS...) along with an audio stream (AC3... AAC... PCM...)

What audio type is being used in what container?
TeetimeNC wrote on 5/9/2014, 1:02 PM
Rob, there may be various examples, but one such recent one is an AVI container with this from Media Info:

Video
Format: AVC
Codec: H.264 video

Audio
Format: ADPCM
Codec ID: 7
Codec ID/Hint: CCITT
Bit rate mode: Constant
Bit rate: 512kbps
Sampling rate: 32.0 KHz

Does this help?

/jerry
Rob Franks wrote on 5/9/2014, 5:21 PM
Why is the sample rate 32?
PeterDuke wrote on 5/9/2014, 11:36 PM
If you watch one of your troublesome clips with one or more reputable media players, do you still see the same out-of-sync problem?

If so, then you will have to fix the problem by hand. In Vegas you can un-group the audio and video and rescale the video or audio so that they are in sync. Depending on the material, this may require a lot of practice.

If the video and audio are in sync with a media player, then demuxing and remuxing may do the trick. Or re-encode your clip to a high quality intermediate, and use that in Vegas.