Splitting .mkv files

MKV playback, recompression, remuxing, codec packs, players, howtos, etc.
Post Reply
macdonjh
Posts: 18
Joined: Sat Dec 05, 2015 11:39 pm

Splitting .mkv files

Post by macdonjh »

I think this has been asked before, but I can't find it, so I'll ask:

I have a few .mkv files, TV series, that have several chapters but each chapter is an episode. What is the right tool to use to split each file into separate files for each episode? MKVToolnix? Is there a utility within MakeMKV for this kind of editing?
Grauhaar
Posts: 566
Joined: Thu Sep 15, 2016 3:46 pm

Re: Splitting .mkv files

Post by Grauhaar »

Can be done with "MKVToolNIX GUI". Go to the output tab and select "Before chapters" and add "all" or specific Chapter numbers.
Good Luck :)
_____________________________________________________________
Useful MakeMKV links: FAQs - Debug Log - Buy - Expiration of beta key
Two Blu-ray (UHD) Drives LG LG BH16NS55 with Libredrive Firmware 1.04
macdonjh
Posts: 18
Joined: Sat Dec 05, 2015 11:39 pm

Re: Splitting .mkv files

Post by macdonjh »

Where can I download MKVToolnix? I tried www.MKVToolNix.download and got some driver optimization subscription service. Don't need that.
Grauhaar
Posts: 566
Joined: Thu Sep 15, 2016 3:46 pm

Re: Splitting .mkv files

Post by Grauhaar »

Just downloaded it from https://www.fosshub.com/MKVToolNix.html (passed from https://mkvtoolnix.download/downloads.html). No problem to get and install it.
Good Luck :)
_____________________________________________________________
Useful MakeMKV links: FAQs - Debug Log - Buy - Expiration of beta key
Two Blu-ray (UHD) Drives LG LG BH16NS55 with Libredrive Firmware 1.04
macdonjh
Posts: 18
Joined: Sat Dec 05, 2015 11:39 pm

Re: Splitting .mkv files

Post by macdonjh »

Got it. Thanks.
macdonjh
Posts: 18
Joined: Sat Dec 05, 2015 11:39 pm

Re: Splitting .mkv files

Post by macdonjh »

Got MKVToolNix, thanks for the help with that. My first couple of attempts produced garbage, can somebody help?

I copied an .mkv file (Part I.mkv) into a "sandbox" folder so I could play with it. I opened the MKVToolNix-GUI and added Part I.mkv to the multiplexer Source window.

Then I moved to the Output tab. I asked for Part I to be "split based on timestamps". I put in time stamps, 0:00:00-0:01:14,0:01:14-0:12:39, et cetera. Eleven new files appeared in my output folder. However, when I tried to play the files (using VLC), all I got was a green screen with some miscellaneous pixels.

Just for grins, I played the original file, Part I.mkv, using VLC and had no trouble, it played fine. Does anyone know what my trouble is?
Grauhaar
Posts: 566
Joined: Thu Sep 15, 2016 3:46 pm

Re: Splitting .mkv files

Post by Grauhaar »

macdonjh wrote:
Tue Aug 13, 2019 9:55 pm
Then I moved to the Output tab. I asked for Part I to be "split based on timestamps". I put in time stamps, 0:00:00-0:01:14,0:01:14-0:12:39, et cetera.
If you hoover over the timestamp input field, the syntax is shown. Do not specify "from-to" timestamps, specify only the timestamp for the split. In youre case "0:01:14, 0:12:39"
Then I tried to play the files (using VLC), all I got was a green screen with some miscellaneous pixels.
You can not split a video file at any timestamp, because it uses GOPs (Group of Pictures). If you specify a timestamp inside a GOP, the startng I-Frame is lost and you have only "delta pictures" without the initial complete picture (I-Frame).

Splits should only be done on Chapter marks, because these are almost set on I-Frame boundary.
Good Luck :)
_____________________________________________________________
Useful MakeMKV links: FAQs - Debug Log - Buy - Expiration of beta key
Two Blu-ray (UHD) Drives LG LG BH16NS55 with Libredrive Firmware 1.04
macdonjh
Posts: 18
Joined: Sat Dec 05, 2015 11:39 pm

Re: Splitting .mkv files

Post by macdonjh »

Grauhaar wrote:
Wed Aug 14, 2019 6:13 am
macdonjh wrote:
Tue Aug 13, 2019 9:55 pm
Then I moved to the Output tab. I asked for Part I to be "split based on timestamps". I put in time stamps, 0:00:00-0:01:14,0:01:14-0:12:39, et cetera.
If you hoover over the timestamp input field, the syntax is shown. Do not specify "from-to" timestamps, specify only the timestamp for the split. In youre case "0:01:14, 0:12:39"
Then I tried to play the files (using VLC), all I got was a green screen with some miscellaneous pixels.
You can not split a video file at any timestamp, because it uses GOPs (Group of Pictures). If you specify a timestamp inside a GOP, the startng I-Frame is lost and you have only "delta pictures" without the initial complete picture (I-Frame).

Splits should only be done on Chapter marks, because these are almost set on I-Frame boundary.
Thank you for helping, Grauhaar.

I read that about the split time stamps and tried only setting the time stamp times, but I didn't get any output. Then I read in the HELP that you can also specify a start and stop time stamp and MKVToolNix will split out that section of the file into a new file. When I did that, I got an output file. Too bad it is garbage.

I also read about the proper frames. The time stamps I used were at the chapter breaks identified by my DVD player (I still have the physical discs), at least to the nearest second. Again, HELP said that MKVToolNix would split the file at the closest proper frame to the time stamp requested. Again. unfortunately I got garbage output.

What is your procedure for splitting files with MKVToolNix? I'm using the ToolNix GUI that was bundled with the program download from the site you suggested, so I'm not using command-line commands.
Grauhaar
Posts: 566
Joined: Thu Sep 15, 2016 3:46 pm

Re: Splitting .mkv files

Post by Grauhaar »

macdonjh wrote:
Thu Aug 15, 2019 9:43 pm
What is your procedure for splitting files with MKVToolNix?
I did it 2-3 times with the chapter split and it works for me.
Good Luck :)
_____________________________________________________________
Useful MakeMKV links: FAQs - Debug Log - Buy - Expiration of beta key
Two Blu-ray (UHD) Drives LG LG BH16NS55 with Libredrive Firmware 1.04
macdonjh
Posts: 18
Joined: Sat Dec 05, 2015 11:39 pm

Re: Splitting .mkv files

Post by macdonjh »

Frustrating, still didn't work. I put the file I wanted split into the FILE NAME box within the Input tab of MKVToolNix.

Then I clicked on the output tab. I didn't add any information in the GENERAL box. In the SPLITTIG box I entered "Before Chapters" from the drop down menu, "all" in the Chapter Numbers field and left Maximum Number of Files as "unlimited".

I didn't enter any other information. I then clicked the "Start Multiplexing" button. I got several new files in my Videos folder, but none of them play properly. The audio is fine, but the video is a green screen (literally) with some random pixels.
Ninko
Posts: 1
Joined: Fri Feb 07, 2020 11:02 pm

Re: Splitting .mkv files

Post by Ninko »

Hi,
This is exactly the same problem I've just come up against. Oddly I've split a few files using this exact method and they have turned out fine.

Any thoughts on this problem?

Thanks


Ninko
mikewohlwend
Posts: 2
Joined: Mon Mar 02, 2020 6:34 pm

Re: Splitting .mkv files

Post by mikewohlwend »

I have a few files that I need to do this to. I will give it a try tonight.
Post Reply