View Full Version : Concatenation problems using MP4
Cocophone
12th November 2006, 01:05
I'm trying to convert bonus features from a dvd to one mp4 file.
What I've tried is using dgindex and then staxrip. For example, I will add 3 vobs to dgindex and get one dv file. I then use this dv file in staxrip. Sometimes I've found that the audio is out of sync on the the last bonus feature in the mp4 file.
What I think is causing the problem is a vob will have different length audio and video tracks. For example:
vob 1 video 11:33:03
vob 1 audio 11:33:01
vob 2 video 15:30:05
vob 2 audio 15:29:58
vob 3 video 10:15:06
vob 3 audio 10:15:04
When I connect all 3 vobs using dgindex and then run it through staxrip the audio and video will be out of sync by 00:00:09 at the start of what was the last vob.
What is the easiest way to make the audio and video tracks the same length before I connect them with dgindex and staxrip?
Could I trim the end off the video track using a mpeg editor?
What should I do if the audio tracks are longer than the video?
What program would be easiest to trim off the end of the audio track?
foxyshadis
12th November 2006, 09:23
One possibility is to index each separately, and in the avisynth use DGDecode("...1")++Dgdecode("...2")++Dgdecode("...3"), assuming the auio is synched correctly in each individually. Then avisynth will deal with the trimming/padding. (The ++ is very important.)
Cocophone
12th November 2006, 17:47
Thanks for the help.
I looked at all the avs files that are used by dgindex and staxrip and here is what I've got. I'm not sure where I would add what you suggest.
American Beauty Look Closer.avs
MPEG2Source("D:\AMERICAN_BEAUTY\Look Closer Behind the Scenes 29-970\American Beauty Look Closer.d2v")
Crop(8,4,-4,-4)
BicubicResize(544,400,0,0.5)
American Beauty Look Closer_AutoCrop.avs
MPEG2Source("D:\AMERICAN_BEAUTY\Look Closer Behind the Scenes 29-970\American Beauty Look Closer.d2v")
ConvertToYV12().AutoCrop(mode=2,samples=20)
American Beauty Look Closer_Source.avs
MPEG2Source("D:\AMERICAN_BEAUTY\Look Closer Behind the Scenes 29-970\American Beauty Look Closer.d2v")
American Beauty Look Closer_StaxRip.log
---------- AviSynth Script ----------
MPEG2Source("D:\AMERICAN_BEAUTY\Look Closer Behind the Scenes 29-970\American Beauty Look Closer.d2v")
Crop(8,4,-4,-4)
BicubicResize(544,400,0,0.5)
---------- Audio Encoding ----------
Command Line: "C:\Program Files\StaxRip\Applications\BeSweet\BeSweet.exe" -core( -input "D:\AMERICAN_BEAUTY\Look Closer Behind the Scenes 29-970\American Beauty Look Closer T01 2_0ch 192Kbps DELAY 0ms.ac3" -output "D:\AMERICAN_BEAUTY\Look Closer Behind the Scenes 29-970\American Beauty Look Closer T01 2_0ch 192Kbps DELAY 0ms_AudioOutput.mp4" ) -azid( -c normal -L -3db ) -ota( -d 0 -g max ) -bsn( -vbr 0.4 -2ch )
---------- Audio Encoding Statistics ----------
Start time: 5:44:43 AM
End time: 5:47:59 AM
Duration: 00:03:15
Speed: 201 fps
Size: 15.2 MB
Bitrate: 97.11 kbps
Video Bitrate: 2175 -> 2138
---------- x264 Single/First Pass Encoding ----------
Command Line: "C:\Program Files\StaxRip\Applications\x264\x264.exe" --pass 1 --bitrate 2138 --stats "D:\AMERICAN_BEAUTY\Look Closer Behind the Scenes 29-970\Temporary Files\American Beauty Look Closer.stats" --bframes 3 --b-pyramid --direct auto --filter -2:-1 --progress --no-psnr --subme 1 --analyse none --me dia --ref 1 --output NUL "D:\AMERICAN_BEAUTY\Look Closer Behind the Scenes 29-970\American Beauty Look Closer.avs"
---------- x264 Single/First Pass Encoding Statistics ----------
Start time: 5:47:59 AM
End time: 6:15:00 AM
Duration: 00:27:01
Speed: 24 fps
---------- Second Pass Encoding ----------
Command Line: "C:\Program Files\StaxRip\Applications\x264\x264.exe" --pass 2 --bitrate 2138 --stats "D:\AMERICAN_BEAUTY\Look Closer Behind the Scenes 29-970\Temporary Files\American Beauty Look Closer.stats" --ref 3 --bframes 3 --b-pyramid --weightb --direct auto --filter -2:-1 --analyse all --8x8dct --subme 6 --me umh --trellis 1 --progress --no-psnr --output "D:\AMERICAN_BEAUTY\Look Closer Behind the Scenes 29-970\American Beauty Look Closer_EncoderOutput.264" "D:\AMERICAN_BEAUTY\Look Closer Behind the Scenes 29-970\American Beauty Look Closer.avs"
---------- Second Pass Encoding Statistics ----------
Start time: 6:15:00 AM
End time: 7:50:57 AM
Duration: 01:35:57
Speed: 7 fps
---------- Muxing ----------
Command Line: "C:\Program Files\StaxRip\Applications\MP4Box\MP4Box.exe" -fps 29.970 -add "D:\AMERICAN_BEAUTY\Look Closer Behind the Scenes 29-970\American Beauty Look Closer_EncoderOutput.264:name=Video" -add "D:\AMERICAN_BEAUTY\Look Closer Behind the Scenes 29-970\American Beauty Look Closer T01 2_0ch 192Kbps DELAY 0ms_AudioOutput.mp4:lang=eng:name=English:sbr" -chap "D:\AMERICAN_BEAUTY\Look Closer Behind the Scenes 29-970\VTS_02 - Chapter Information - OGG.txt" -new "D:\AMERICAN_BEAUTY\Look Closer Behind the Scenes 29-970\American Beauty Look Closer.mp4"
---------- Muxing Statistics ----------
Start time: 7:50:57 AM
End time: 7:53:47 AM
Duration: 00:02:50
Speed: 231 fps
---------- Overall Statistics ----------
Start time: 5:44:43 AM
End time: 7:53:47 AM
Duration: 02:09:03
joseph5
12th November 2006, 21:18
You have to create one d2v file from each bonus, then change the first line of each script to:MPEG2Source("D:\AMERICAN_BEAUTY\Look Closer Behind the Scenes 29-970\American Beauty Look Closer1.d2v")++MPEG2Source("D:\AMERICAN_BEAUTY\Look Closer Behind the Scenes 29-970\American Beauty Look Closer2.d2v")++MPEG2Source("D:\AMERICAN_BEAUTY\Look Closer Behind the Scenes 29-970\American Beauty Look Closer3.d2v")
vBulletin® v3.8.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.