View Full Version : sync problems when joining mp4 files in yamb
narco220
13th September 2007, 14:30
I have a H.264.mp4 enoded movie thats been split into 4 scenes.
I tried to join them with yamb but got sync problems can anyone help?
thanx
Drachir
14th September 2007, 12:18
Maybe the files, you try to append, have diffrent track durations for audio and video. Try if this help:
Take a look at each file with "MP4Box -info yourFile.mp4" and write down the milliseconds the track duration differ.
Then add to each file/track, you try to append, the delay (difference of track duration from the file before). Something like this:
MP4Box -info file1.mp4
* Movie Info *
....
Track # 1 Info - TrackID 201 - TimeScale 15000 - Duration 01:45:25.933
Media Info: Language "Undetermined" - Type "vide:mp4v" - 94576 samples
MPEG-4 Config: Visual Stream - ObjectTypeIndication 0x20
MPEG-4 Visual Size 320 x 192 - Simple Profile @ Level 3
Pixel Aspect Ratio 1:1 - Indicated track size 320 x 192
Synchronized on stream 1
Track # 2 Info - TrackID 101 - TimeScale 24000 - Duration 01:45:25.674
Media Info: Language "Undetermined" - Type "soun:mp4a" - 148258 samples
MPEG-4 Config: Audio Stream - ObjectTypeIndication 0x40
MPEG-4 Audio AAC LC - 2 Channel(s) - SampleRate 24000 - SBR SampleRate 48000
Synchronized on stream 1
....
MP4Box -delay 2=259 file2.mp4
Do this with all files you try to append. Set for every file a delay which is equal to the track duration difference of the file before. After you have done this concatenate all files.
bond
16th September 2007, 12:38
as drachir said + in case the audio is longer than the video you can try to cut the longer audio to match the video
also make sure that all parts use the correct framerate (the fps of the parts can also differ)
Tonttu
12th November 2007, 21:21
I have a problem maybe related to this. I have a couple of pairs of clips I need to join, but when I do, it results in a video that has two streams playing at once, the other in a "hardware YUV directx output" window (VLC/MediaPl.Cl.).
As an example, infos for a pair:
This is for the opening clip:
Track # 1 Info - TrackID 1 - TimeScale 25 - Duration 00:00:17.880
Media Info: Language "Undetermined" - Type "vide:avc1" - 447 samples
MPEG-4 Config: Visual Stream - ObjectTypeIndication 0x21
AVC/H264 Video - Visual Size 720 x 544 - Profile Main @ Level 5.1
NAL Unit length bits: 32
Self-synchronized
Track # 2 Info - TrackID 2 - TimeScale 48000 - Duration 00:00:18.005
Media Info: Language "English" - Type "soun:mp4a" - 422 samples
MPEG-4 Config: Audio Stream - ObjectTypeIndication 0x40
MPEG-4 Audio AAC LC - 2 Channel(s) - SampleRate 24000 - SBR SampleRate 48000
Synchronized on stream 1
This is the info for the file that will come after:
Track # 1 Info - TrackID 1 - TimeScale 25000 - Duration 01:01:06.280
Media Info: Language "Undetermined" - Type "vide:avc1" - 91657 samples
MPEG-4 Config: Visual Stream - ObjectTypeIndication 0x21
AVC/H264 Video - Visual Size 720 x 544 - Profile Main @ Level 5.1
NAL Unit length bits: 32
Pixel Aspect Ratio 1:1 - Indicated track size 720 x 544
Self-synchronized
Track # 2 Info - TrackID 2 - TimeScale 48000 - Duration 01:01:06.389
Media Info: Language "Undetermined" - Type "soun:mp4a" - 85931 samples
MPEG-4 Config: Audio Stream - ObjectTypeIndication 0x40
MPEG-4 Audio AAC LC - 2 Channel(s) - SampleRate 24000 - SBR SampleRate 48000
Synchronized on stream 1
What should I put for the delays and can I do it in YAMB (properties..)? :stupid: Is this going to affect the playback on some mp4 players? Thanks.
vBulletin® v3.8.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.