Discussion Forums > Technology

A/V sync problems with selfmade MKVs... Help?

<< < (2/3) > >>

iindigo:

--- Quote from: nstgc on January 10, 2010, 12:38:10 PM ---Also try this: --default-duration 0:30000/1001fps

--- End quote ---

I fail to see how this will help when the --default-duration argument is being ignored totally, but if you insist I'll try it anyway.



--- Quote from: fohfoh on January 11, 2010, 03:42:42 AM ---So you're having issues with the hard subs? Did you try toying around with soft subs?

--- End quote ---

It's all explained in the original post, but here's a basic breakdown.

- I previously owned a DVD rip of this anime. Its SSA softsubs look great, but its video and audio kinda sucked.
- I recently obtained Exiled-Destiny's release of the same anime. Video and audio are great, but makes use of ass-ugly vobsubs (yellow, jagged, sitting-nearly-in-the-middle-of-the-screen, distracting DVD subs) and has the English dub set to default.

My intent was to combine the best from both releases, resulting in a dual-audio, SSA-subbed, japanese-default version of the anime with high video and audio quality.



--- Quote from: Slysoft on January 11, 2010, 06:49:22 AM ---get mkvtoolnix. It can't be any simpler. You just import the audio, video, and subtitle files and hit mux. Of course there are a ton of advanced settings but I don't mess with those. There's also a GUI or a command line version depending on which you prefer. This program is acknowledged by matroska themselves, so you can be sure that it's good.

http://www.bunkus.org/videotools/mkvtoolnix/index.html

It also works good for ripping tracks out of the mkv, if you for example liked one group's video but another group's subs.

--- End quote ---

Yes, the individual programs within the MKVToolnix package are what I'm currently using. They're commandline-only, since the UI is not functional on my ancient PowerPC Mac, but they seem to get the job done.

Blanchimont:
You're having the problem because most of E-D's encodes are vfr (variable framerate)...

So if you simply demux, and later remux the streams, of course they're going to be out of sync...

You have mkvtoolnix? Good, now get the add-on mkvextract to it unless you already have it, and extract the timecodes file from the original file.
When you mux back, just add the timecodes file (there's a selection for it on mkvmerge front, if you're using the gui), and voila, the remuxed file should be in sync :)

One problem you might also run into is if the audio is tagged with delay, but you should see what the delay is in the demuxed streams' names. If needed, just fill the right prompt in mkvmerge when remuxing with those values...

As for vfr, it's probably a lot easier to understand if you approach it from a completely different angle and forget all about normal framerates... Think of it as a set of frames with each having a set time to appear on the screen, and the player reads those times from the timecodes file where they are noted for each frame.*
 (*...if the timecodes file is v2 format, and that is what you get if you get it with mkvextract).

Most times vfr/variable framerate doesn't refer to encodes with very varying times for the frames globally (true vfr), but to encodes with both 24 fps & 30 fps sections, such E-D's encodes...

iindigo:

--- Quote from: Blanchimont on January 11, 2010, 03:17:24 PM ---You're having the problem because most of E-D's encodes are vfr (variable framerate)...

So if you simply demux, and later remux the streams, of course they're going to be out of sync...

You have mkvtoolnix? Good, now get the add-on mkvextract to it unless you already have it, and extract the timecodes file from the original file.
When you mux back, just add the timecodes file (there's a selection for it on mkvmerge front, if you're using the gui), and voila, the remuxed file should be in sync :)

One problem you might also run into is if the audio is tagged with delay, but you should see what the delay is in the demuxed streams' names. If needed, just fill the right prompt in mkvmerge when remuxing with those values...

As for vfr, it's probably a lot easier to understand if you approach it from a completely different angle and forget all about normal framerates... Think of it as a set of frames with each having a set time to appear on the screen, and the player reads those times from the timecodes file where they are noted for each frame.*
 (*...if the timecodes file is v2 format, and that is what you get if you get it with mkvextract).

Most times vfr/variable framerate doesn't refer to encodes with very varying times for the frames globally (true vfr), but to encodes with both 24 fps & 30 fps sections, such E-D's encodes...

--- End quote ---

Indeed. I have the entire MKVToolnix suite installed and have been using them all the whole time... they come as a package deal when installed through the port package manager, you see ;)

And yes, I tried toying with VFR before, extracting the timecodes from the E-D file and applying it to my freshly made MKV. Similarly to setting --default-duration, the codes were simply ignored and the video continued to play back at 25FPS. Perhaps I did something wrong, so I'll give it another shot...

fizzmaister:
I don't know how much this will help you, but this is what I do in mmg (the gui for mkvMerge), maybe you can figure out the command line equivalent. Instead of extracting everything with mkv extract and then putting what I want back and adding the new things, I open the existing file in mmg, select the tracks that I want to keep, and add new tracks. Here are a few things that it spits out as the command line equivalent.

(click to show/hide)
--- Code: mkv imported in mmg, all tracks selected (1V, 1A, 1S) ---"mkvmerge" -o "C:\Users\Fizz\Desktop\00\S1\[Conclave-Mendoi]_Mobile_Suit_Gundam_00_-_01v2_[1280x720_H.264_AAC][871FCBC2].mkv"  --language 1:jpn --track-name "1:Video (h.264)" --default-track 1 --display-dimensions 1:1280x720 --language 2:jpn --track-name "2:Japanese Audio (2ch LC-AAC)" --default-track 2 --language 3:eng --track-name "3:English Subtitles (ASS)" --default-track 3 -a 2 -d 1 -s 3 C:\Users\Fizz\Desktop\00\S1\[Conclave-Mendoi]_Mobile_Suit_Gundam_00_-_01v2_[1280x720_H.264_AAC][871FCBC2].mkv --track-order 0:1,0:2,0:3 --title "[Conclave-Mendoi] Mobile Suit Gundam 00 - Episode 1"
--- End code ---



--- Code: mkv importing only what I want (no sub) 1V, 1A ---"mkvmerge" -o "C:\Users\Fizz\Desktop\00\S1\[Conclave-Mendoi]_Mobile_Suit_Gundam_00_-_01v2_[1280x720_H.264_AAC][871FCBC2].mkv"  --language 1:jpn --track-name "1:Video (h.264)" --default-track 1 --display-dimensions 1:1280x720 --language 2:jpn --track-name "2:Japanese Audio (2ch LC-AAC)" --default-track 2 -a 2 -d 1 -S C:\Users\Fizz\Desktop\00\S1\[Conclave-Mendoi]_Mobile_Suit_Gundam_00_-_01v2_[1280x720_H.264_AAC][871FCBC2].mkv --track-order 0:1,0:2 --title "[Conclave-Mendoi] Mobile Suit Gundam 00 - Episode 1"
--- End code ---



--- Code: mkv importing what I want, plus external subs. 1V, 1A, 1S ---"mkvmerge" -o "C:\Users\Fizz\Desktop\00\S1\[Conclave-Mendoi]_Mobile_Suit_Gundam_00_-_01v2_[1280x720_H.264_AAC][871FCBC2].mkv"  --language 1:jpn --track-name "1:Video (h.264)" --default-track 1 --display-dimensions 1:1280x720 --language 2:jpn --track-name "2:Japanese Audio (2ch LC-AAC)" --default-track 2 -a 2 -d 1 -S C:\Users\Fizz\Desktop\00\S1\[Conclave-Mendoi]_Mobile_Suit_Gundam_00_-_01v2_[1280x720_H.264_AAC][871FCBC2].mkv -s 0 -D -A "C:\Users\Fizz\Desktop\00\S1\better subs.ass" --track-order 0:1,0:2,1:0 --title "[Conclave-Mendoi] Mobile Suit Gundam 00 - Episode 1"
--- End code ---

I hope with these command line entries, you'll be able to get something to work without the gui. Best of luck.

nstgc:

--- Quote from: iindigo on January 11, 2010, 01:55:48 PM ---
--- Quote from: nstgc on January 10, 2010, 12:38:10 PM ---Also try this: --default-duration 0:30000/1001fps

--- End quote ---

I fail to see how this will help when the --default-duration argument is being ignored totally, but if you insist I'll try it anyway
--- End quote ---

What I was thinking was perhaps it didn't like the "1:29.970fps" you specified earlier. I found that some programs don't like it when you use decimals and preffer expressing it as a fraction. MEncoder is like that. I know that you aren't using MEncoder, but I figured I'd throw it out there.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version