Hi. I'm using MKVEGUI to extract files from some MKV files I downloaded, and it seems to work fine. But when I compare the video and audio tracks, I find that the video is about 4 minutes shorter than the audio, even though both seem to be intact. Can anyone help me with this?
+ Reply to Thread
Results 1 to 24 of 24
-
-
MKV supports VFR (Variable Frame Rate), if you have such a file and you assume that the video is CFR then the length won't match the audio.
-
Originally Posted by celtic_druid
-
The avi container doesn't support VFR so it has no choice and neither do you. The extracted avi simply won't match the audio.
-
Originally Posted by celtic_druid
-
What do you mean? You don't know why they used mkv? If you have a VFR source then surely it makes sense to use mkv so you can keep it VFR? mkv is no the problem. The problem is that you have a VFR source, when you don't want one.
Also I never said that it wasn't possible to have an avi that was in sync, just that the extracted video would never match. It is possible to convert to an avi, you have to re-encode the video though, changing the framerate. -
Originally Posted by celtic_druid
-
My problem is that I don't know how to recode the avi so that it will match the audio. My audio files have 23'42" and the subtitle file matches them. However, the avi file, when extracted from the mkv, has only 18'42".
-
@ikarishinji,
You can use Virtualdubmod to demux the video and audio to wav. Then use Virtualdubmod to mux the video and wav file.
Edit - when you demux the video - use direct stream and demux audio use full processing. if there is a window pop up when you first load your video file and asking you to fix the audio, just close it and don't fix it. -
Thanks for the tip, pchan. Sorry for the ignorance, however, but how do I do that? I know how to demux files in Virtualdubmod, but not how to do the other way around.
-
That won't change the fact that the video and audio won't be the same length though.
You could open the mkv using AVISynth with directshowsource(). If you check the AVISynth docs on directshowsource it even mentions VFR mkv's. Other option is to use the time codes from the mkv and set it all up manually. -
@celtic_druid,
I was having audio sync problem several days ago converting from Divx to MPEG2 using TMPEGEnc. Convert the audio to wav format and it encoded OK.
@ikarishinji41,
Assuming you already demux the video and audio, you will have a demuxed video file without audio and an audio file in wav format. Open the demuxed video file from Virtualdubmod and click Streams and select Stream List and add the wav file. Go to Video and select Direct Stream Copy. Finally, go to file and select Save As.... ... you have Divx with wav audio. -
I just finished encoding the video and audio with Virtualdubmod using DivX compression and an option to match the video and audio length. I got an avi file with audio, and it's now the same length of the audio (25:43) but they still don't match. the video still runs much faster than the audio. Then, I tried pchan's suggestion and muxed them using direct stream copy. Same result.
-
@ikarishinji41,
Did you demux the audio to wav format using full processing ? -
Yes, wav file is large. Usually, it's around 200~300M bytes for a 1.5hr video clip. I muxed it back to Divx and encoded to MPEG2 with TMPEGEnc.
-
No, I mean, when I use full processing for the video it gets to more than 18GB. But even when I got the video and audio to be the same length (23:42) they're still out-of-sync. As I don't know how to use scripts, I'm also unable to try Avisync.
-
@ikarishinji41,
I not sure you have already tried what I have suggested. Demuxed the video using direct stream and audio to wav using full processing. Finally, mux video and audio. Then, you do the encoding.
I did that for clips that are out of sync. -
I don't know how to mux them together. I have never done that. As for extracting them, I have to do it with MKVEGUI because VirtualDubMod won't even open the MKV files I have.
-
I tried adding the audio stream which I converted from aac (that VirtualDubMod doesn't reckognize) to wave to the Stream List. Them I saved the file using Direct Stream Copy. Audio and video are still out-of-sync by almost a minute.
-
Originally Posted by celtic_druid
-
Well you would need to look at the time codes then create an AVISynth script splitting it up based on the time codes and creating a CFR of ~120fps. So the 23.976fps sections get 5 duplicate frames, the 29.97fps sections 4, etc. Easier I would think would be AVISynth with directshow source and convert fps. There is even an example refering to VFR source files in the AVISynth docs.
-
Can anyone tell me how I can recode an avi file so that it'll get from 20min13s to 24min13s duration? That's the ratio difference between my video and audio files.
Similar Threads
-
Extract subs from MKV and other attached files
By nohocker in forum Newbie / General discussionsReplies: 2Last Post: 14th Feb 2012, 00:16 -
Can't Extract .srt files from .mkv file
By koenf1 in forum SubtitleReplies: 1Last Post: 1st Nov 2010, 14:11 -
how to extract an audio track form MKV files??
By Sh@DY in forum Video ConversionReplies: 2Last Post: 15th Sep 2010, 06:42 -
Stripping sections of MKV files to seperate smaller MKV files
By spudz72 in forum EditingReplies: 6Last Post: 29th Jul 2010, 01:53 -
How to extract Subtitles from .MKV files?
By kehn in forum SubtitleReplies: 4Last Post: 20th Nov 2007, 06:14