User(s) browsing this thread: 2 Guest(s)
|
Combining audio and video with different fps
|
|
10-05-2010, 03:58 AM
(This post was last modified: 10-05-2010 04:45 AM by cheaper_popcorn.)
|
|||
|
|||
|
Combining audio and video with different fps
I have a DVD containing a 2.0 AC3 (Dolby Digital) audio track of 25fps.
I also have the same movie in an MP4 container, but as 23.976fps AVC - the video quality is better, but it does not have the audio track I want. What is the best method of combining the two? More specifically, here are the media info outputs. From the DVD: Code: GeneralSo I'd like to demux the 'Language 2' audio from the DVD. And here is the mp4 mediainfo output: Code: GeneralFor my purposes, I think it would make the most sense to output the final version to MKV using MKV Merge. But I have never extracted audio from a DVD before, nor do I know exactly what I need to do, and which tools I need to use, to sync the 'Language 2' AC3 audio from the DVD, with the AVC video track from the mp4 file. Media tank:A-100 & C-200 TV:Panasonic TH-50PY800MT (HDMI) Audio:Logitech Z-5500 (Coaxial) |
|||
|
10-05-2010, 05:15 AM
|
|||
|
|||
|
RE: Combining audio and video with different fps
Quite a task ahead of you - first you would have to demux the DVD to extract the AC3 25fps audio file that you need. Then you would have to convert that file to preferably PCM using a wave editor like Adobe Audition or similar so that you can make timing adjustment 25/23.976 or is it 23.976/25 =
Best combine the vobs as a single large vob (makes life easier in editing) before attempting to extract the AC3 file and DVDShrink will do it - just change the default split in preferences to one large file. VirtualDub load VOB's and save as wave DVD AudioExtractor or Demux with DVDDecrypter Popcorn Hour C200 HDMI BeyonWiz DP-P1 PVR + LiDiC Component Video 1080i Samsung LA40R7 LCD TV SONY STR-DA1000ES amplifier Windows 7 -- MAC G4 http://www.openwiz.org/wiki/ProjectX |
|||
1 user says Thank You to Netmask for this post |
|
10-05-2010, 06:07 AM
(This post was last modified: 10-05-2010 06:30 AM by cheaper_popcorn.)
|
|||
|
|||
|
RE: Combining audio and video with different fps
Thank you. I just successfully ripped the desired audio from the DVD using DVD Decrypter following this guide: http://www.dvd-guides.com/content/view/136/59/ (I stopped before using Goldwave though).
Also, I just had a thought: Does the frame rate of the audio matter, now that it is extracted? I am thinking that once I mux the audio into the MKV, won't the only important parameters be track length, i.e. if we presume the audio track and video track are the exactly same length (probably not the case but for the sake of the argument), then would it not work to just mux the untouched ripped AC3 track into the MKV with the video, set the output framerate to 23.976, and get proper sync? I think I will start by loading the AC3 track and AVC video track in mkvmerge to see if it tells me the length of the respective tracks. Just for the hell of it, I tried muxing the two tracks together. It did not work: the result gradually goes out of sync. (The video track is longer than the AC3 track). So it was obviously not quite that simple, I guess I just wanted to try anyway, not much time lost. ![]() EDIT: Next thought: maybe the conversion to WAV would not cause any loss in audio quality compared to the original AC3 (which is already 2.0)? And then, after converting the WAV track, instead of going back to AC3 again, I could convert to FLAC to avoid loss? How about that plan? Media info output from the extracted AC3 track: Code: GeneralSo the audio track length 1h22 min, while the movie track is 1h 26 min. Media tank:A-100 & C-200 TV:Panasonic TH-50PY800MT (HDMI) Audio:Logitech Z-5500 (Coaxial) |
|||
|
10-05-2010, 06:33 AM
|
|||
|
|||
|
RE: Combining audio and video with different fps
You will need to stretch the audio track to match and this a lot easier to do as a wave file - there will be no loss of quality going AC3 2 track to wave if you keep the sampling rate at 48kbps. If you stretch the audio to fit the length you should also do a pitch correction as the difference is over 4% ala 24fps films being shown on PAL TV at 25 fps and the reverse. If the Popcorn will play a video file with a FLAC audio go for it so far I haven't seen/heard one - mostly AC#, PCM or MP3
Popcorn Hour C200 HDMI BeyonWiz DP-P1 PVR + LiDiC Component Video 1080i Samsung LA40R7 LCD TV SONY STR-DA1000ES amplifier Windows 7 -- MAC G4 http://www.openwiz.org/wiki/ProjectX |
|||
|
10-05-2010, 06:39 AM
(This post was last modified: 10-05-2010 06:40 AM by cheaper_popcorn.)
|
|||
|
|||
|
RE: Combining audio and video with different fps
Thanks again for you time. Will not the speedup and pitch correction cause some loss though? I suppose loss may just be unavoidable?
Media tank:A-100 & C-200 TV:Panasonic TH-50PY800MT (HDMI) Audio:Logitech Z-5500 (Coaxial) |
|||
|
10-05-2010, 08:18 AM
(This post was last modified: 10-05-2010 08:22 AM by jj666.)
|
|||
|
|||
|
RE: Combining audio and video with different fps
- rip both disks with MAKEMKV (name: assuming DVD1.mkv is the source you want to slowdown and DVD2.mkv is the 23.976 (29.997) source) and use EAC3TO slowdown the 25fps disk to 23.976fps. We convert the AC3 track to FLAC to keep it as-lossless-as-possible.
- EAC3TO DVD1.mkv 1: video.mkv -25.000 -slowdown 2: audio.flac -25.000 -slowdown. - Mux resultant audio.flac with DVD2.mkv. - To ascertain if there is an initial sync if needed, would suggest playing back both files (DVD2.mkv and newly created video.mkv) in MPC-HC with FFDSHOW decoding the video, turn on the OSD in FFDSHOW to display "current frame number" and "frame duration". Locate a suitable frame, ie, scene change, or logo coming onto the screen in both DVD's and make sure the frame number is the same. You can pause the video using space and step through frames with the left and right arrow keys. If not identical, you can work out a delay needed by number of frames difference x frame duration and add/deduct this to the audio stream by remuxing again with MKVMERGE and manually adding the delay there. As long as both copies of the film are identical (ie, no different cuts between the two versions) you should be fine with just checking the initial sync. Cheers, -jj- PCH C-200 + LG GGC-H20L internal Blu-ray drive · YAMJ plus Aeon Wall · Samsung LE-46A956 · Sony STR-DG820 · JBL CS 1500 · 2 x 40TB Unraid servers |
|||
1 user says Thank You to jj666 for this post |
|
10-05-2010, 10:20 AM
(This post was last modified: 10-05-2010 10:25 AM by cheaper_popcorn.)
|
|||
|
|||
|
RE: Combining audio and video with different fps
Thanks jj666.
Being the stubborn and lazy person I am, I have been trying to exclusively use mkvmergeGUI to correct the synch. First thing I tried was to use 'Stretch by' on the audio track. I used VLC to note down the track times for video and audio, and then converted into seconds. I got a value of 4969 s for the audio and 5696 s for the video. I selected the audio track, then opened the tab 'Format specific options' and put 4969/5696 into the 'Stretch by' box. The result was not usable. The audio track did not respond well at all to the option 'Stretch by' (to be fair, the mouseover help text of mkvmerge GUI does mention that 'Stretch by' works best for video and subtitle tracks). The resulting audio had minor glitches throughout, it seems as what it did was to insert regular micro-pauses to fill out the track and adjust it to fit the video. Obviously this was not an acceptable solution. The second thing I did was to apply the Stretch by to the video track instead. I selected the video track and put 5696/4969 in the 'Stretch by' box. The resulting file looked quite good upon playback in VLC player - no noticeable glitches in the video even on panning, and the audio track, obviously, stays intact when using this method. I had near perfect sync around the first 12 minutes. I think one of the main problems I have is that the two versions are very close, but not exactly the same throughout. I will now find where the cuts are, and use a wav editor as suggested by Netmask, so I can add or remove required milliseconds of silence where necessary, before converting to FLAC and using MKVmerge. Media tank:A-100 & C-200 TV:Panasonic TH-50PY800MT (HDMI) Audio:Logitech Z-5500 (Coaxial) |
|||
|
10-05-2010, 10:36 AM
|
|||
|
|||
|
RE: Combining audio and video with different fps
In fact, I don't know anybody using such methods to do things with MKVMERGE. You're making something extremely easy, extremely complicated.
EAC3TO is a tried, trusted and working solution (also for slowing down EUR HDTV caps for viewing in US etc). If you have any sync issues after setting the initial sync, you know it's a result of differences in the two films, rather than in the process, so can act accordingly (ie, check the waveforms). For waveform editing, I'm using Adobe Audition to find the differences, then eac3to to make the necessary edits. If you get to that stage, I can offer further advice, just let me know. Cheers, -jj- PCH C-200 + LG GGC-H20L internal Blu-ray drive · YAMJ plus Aeon Wall · Samsung LE-46A956 · Sony STR-DG820 · JBL CS 1500 · 2 x 40TB Unraid servers |
|||
|
10-05-2010, 11:28 AM
(This post was last modified: 10-05-2010 11:30 AM by cheaper_popcorn.)
|
|||
|
|||
|
RE: Combining audio and video with different fps
I've tried eac3to for the first time now.
Re-encoding the AC3 to FLAC reduced the bit depth (from 64 to 24) and since there is no pitch correction, the voices sound rather different, like they're dragging their heels or want to emphasize every word, the father's tenor/baritone is now a bass. The conversion also removed AC3 dialog normalisation (previously set to -27dB). Did I do something wrong here, or would you characterize these changes/reductions in audio quality as acceptable? I did notice eac3to recommends installing Nero7 to improve AC3 decoding so maybe I will try that. Media tank:A-100 & C-200 TV:Panasonic TH-50PY800MT (HDMI) Audio:Logitech Z-5500 (Coaxial) |
|||
|
10-05-2010, 11:42 AM
(This post was last modified: 10-05-2010 11:42 AM by jj666.)
|
|||
|
|||
|
RE: Combining audio and video with different fps
You can use -keepdialnorm switch to preserve the dialog normalisation if you want. There aren't a huge amount of PAL pitch shifted DVDs at least in English - what you're probably hearing is the original, as intended, audio. What language/disk are you working with there?
The libav decoder in EAC3TO these days is more than adequate for AC3 decoding, so no need for Nero :-) Cheers, -jj- PCH C-200 + LG GGC-H20L internal Blu-ray drive · YAMJ plus Aeon Wall · Samsung LE-46A956 · Sony STR-DG820 · JBL CS 1500 · 2 x 40TB Unraid servers |
|||
1 user says Thank You to jj666 for this post |
|
10-05-2010, 11:52 AM
(This post was last modified: 10-05-2010 11:55 AM by cheaper_popcorn.)
|
|||
|
|||
|
RE: Combining audio and video with different fps
Actually the sync is close to excellent for the resulting FLAC track, definitely superior to what I got when playing with MKV Merge, so thank you for persisting despite my stubbornness.
And it is quite possible you are right about this pitch being correct. So I would not gain anything by going to RAW or WAV first and then to FLAC, such as being able to keep the bit depth? Media tank:A-100 & C-200 TV:Panasonic TH-50PY800MT (HDMI) Audio:Logitech Z-5500 (Coaxial) |
|||
|
10-05-2010, 12:02 PM
|
|||
|
|||
|
RE: Combining audio and video with different fps
Bit depth is irrelevant when working with lossy recordings, so you can ignore that 64bit -> 24bit reference (for more info do a quick search on Doom9). EAC3TO is decoding and encoding to FLAC on the fly, so no, no advantage to changing to another container before conversion.
Regarding the pitch, is it English audio? If so, let me know the movie, maybe I have it already in 23.976fps and we can check the pitch with a quick uploaded AC3 track? Cheers, -jj- PCH C-200 + LG GGC-H20L internal Blu-ray drive · YAMJ plus Aeon Wall · Samsung LE-46A956 · Sony STR-DG820 · JBL CS 1500 · 2 x 40TB Unraid servers |
|||
|
10-05-2010, 12:05 PM
(This post was last modified: 10-05-2010 12:05 PM by cheaper_popcorn.)
|
|||
|
|||
|
RE: Combining audio and video with different fps
Thanks again for the further explantion. No, it's actually a Swedish audio track so I guess that wouldn't work.
Media tank:A-100 & C-200 TV:Panasonic TH-50PY800MT (HDMI) Audio:Logitech Z-5500 (Coaxial) |
|||
|
10-05-2010, 12:12 PM
|
|||
|
|||
|
RE: Combining audio and video with different fps
If it's from the Dragon Tattoo series or Let The Right One In, it works, apart from that, I'm not sure I have many Swedish movies ;-)
Cheers, -jj- PCH C-200 + LG GGC-H20L internal Blu-ray drive · YAMJ plus Aeon Wall · Samsung LE-46A956 · Sony STR-DG820 · JBL CS 1500 · 2 x 40TB Unraid servers |
|||
|
« Next Oldest | Next Newest »
|
| Possibly Related Threads... | |||||
| Thread: | Author | Replies: | Views: | Last Post | |
| 1080P MKV No audio | maartendem | 2 | 1,412 |
12-28-2012 01:22 AM Last Post: chris57 |
|
| Video quality of different media streamers | john_C200 | 11 | 4,436 |
02-06-2012 01:50 PM Last Post: john_C200 |
|
| Video Card Junkies Help me out | Polo151821 | 4 | 1,494 |
11-24-2011 06:20 PM Last Post: Polo151821 |
|
| wifi audio stream to iphone | crazyboss | 2 | 2,560 |
11-23-2011 12:57 AM Last Post: crazyboss |
|
| Re: mkv file no video display on my plasma | virtual_ghost | 6 | 2,656 |
10-22-2011 10:10 AM Last Post: chris57 |
|
| tsMuxer default audio track | Bazrah | 1 | 1,650 |
01-28-2011 05:08 PM Last Post: jj666 |
|
| Egreat EGR1 CD AUDIO | gregoryt | 1 | 1,450 |
12-14-2010 11:03 AM Last Post: chris57 |
|
| In-car video player? | NumberSix | 9 | 2,920 |
11-11-2010 02:17 PM Last Post: NumberSix |
|
| What shud be my Video Output on NMT ? | sando | 0 | 1,190 |
11-10-2010 11:28 PM Last Post: sando |
|
| I'm confused on audio formats | ckl_88 | 7 | 2,039 |
10-27-2010 09:00 AM Last Post: Pernod |
|

Twitter
Facebook
NMT Wiki
Search
Member List
Help
A-400 [13 May 2013]




![[+]](images/collapse_collapsed.gif)



