Page 1 of 1

I need Movies2MKV Converter or instructions on batch conversion

Posted: Sun Sep 24, 2023 6:32 pm
by galapogosian
I found the forum while looking for a batch converter from VIDEO_TS to mkv. It sounds like Movies2MKV Converter did exactly what I wanted, which was to convert the VIDEO_TS to mkv, put the new file in the folder the source was in, and delete the source once converted. But Movies2MKV Converter does not seem to be available anymore, and I cannot find an old version online. This is where I was looking: viewtopic.php?f=10&t=7960

I have a ton of files to convert, and I really need a set it and forget it option. Can you please tell me where to get the software or how to batch convert with MakeMKV?

Re: I need Movies2MKV Converter or instructions on batch conversion

Posted: Mon Sep 25, 2023 12:52 pm
by d00zah
This may/may not help? The referenced link is still active.

edit: Just checked the 1st post of this topic & the download link is active there, too, as well as setup instructions w/ images.

viewtopic.php?p=40286#p40286

Re: I need Movies2MKV Converter or instructions on batch conversion

Posted: Thu Sep 28, 2023 2:02 am
by galapogosian
I tried to get that to work and gave up. I did them individually. Thanks for the reply, though.

Re: I need Movies2MKV Converter or instructions on batch conversion

Posted: Sat Nov 04, 2023 12:26 am
by just4kicks
[UPDATE:] This doesn't quite work all the time. Some DVD ISOs it did not import all of the episodes to MKV, but the GUI is able to. I will leave the batch script code and post in case you can use it to batch something you want, other than that, sorry - hope I can figure out how to get makemkvcon64 get all the titles and not skip some.

----------------------------------------------------------


If it helps, in my situation, I had ISO files ripped to my hard drive, but not every TV stream player or TV OS supports ISO files, so I decided to try MKV files. I have a heck-ton of them, so manually doing it would be painful, so here's what I came up with in a DOS Batch file (Windows, I was too lazy to install MakeMKV on my Linux box):

Note: I know it's sloppy coding to change drives in a batch file, but I was in a hurry and was having problems pulling up the list of *.iso with G in the name, so I wimped out and just said go to G: (I am also using a %%G variable/token - that is a coincidence and the two are not related to each other). I also know I could have done variables to make changes easier, but again, when I did this, I saw it as a single use/purpose batch for me. Feel free to pretty up on your own if you like.

------------------------- BATCH --------------------------

Code: Select all

@echo off
G:
for /r %%A in (*.iso) DO (
	echo %%A
	for /f "tokens=*" %%G in ('dir /b "%%A"') DO (
		mkdir "I:\%%G"
		E:\video\makemkvcon64.exe info "%%A" > E:\video\title.txt
		FOR /F "tokens=2 USEBACKQ" %%F IN (`findstr /C:"Title  " E:\video\title.txt`) DO (
			echo %%F
			E:\video\makemkvcon64.exe mkv "%%A" %%F I:\%%G
		)
	
	)
	
)
----------------------- END BATCH -----------------------

G: is where my ISOs are stored for this procedure - it's all I used that drive for for conversion
I: is where I am placing the MKV files
E:\video is where I manually copied files from the C:\Program Files (x86)\makemkv folder to for easier manipulation in the command line (for me)
%%A is my token variable for each ISO file found as the loop goes through, one at a time, and contains the FULL path (which I can't work with, or don't want to)
%%G is my token variable for each ISO filename only (no path)
%%F is my token variable for each title track identifier that I will send to makemkvconv64 to convert.
*** there is no reason I chose %%A, %%F, and %%G - just randomly taken/used


Explanation:
1) change to my temporary ISO storage drive (I recommend you don't read/write to the same drive unless you have an SSD)

2) for /r is a recursive listing for ISOs found on my G: drive. Basically, on the G: drive, I have ISOs in folders and subfolders and I am doing a drill down as far as dos can go to get the ISO file names and folders. This is assigned the %%A token variable.

3) I echo the value of %%A for troubleshooting and debugging (you can REM this out if you don't need it)

4) Next, I take the %%A variable, and I create a dir /b listing (bare format, no heading, details - just filenames) and store that (each individually through the iteration of the loop) as %%G token variable (essentially tossing the full path and just getting the filename)

5) I echo the value of %%G for troubleshooting and debugging (you can REM this out if you don't need it)

6) Next, if not already created, I created a folder named after the ISO image file name (%%G) (this helps keep the files you create separate since some titles don't label the titles very well or makemkv doesn't read them very well, and they end up like "C1_t00.mkv". Another disc with the same title issue, would overwrite that file if you put them all in the same folder for different discs/ISOs, so I keep them separated by creating a folder from the %%G variable.
For example, G:\ABC\123\ABC123.iso file would create a folder called \ABC123.iso\... on the I:\ drive and the mkv files for THAT iso image file would then go into this folder

7) Next, I need to extract title info from the ISO so I can ask makemkvcon64 to go convert them. I call the file title.txt and I place that file in E:\video\title.txt to be used later in the loop

8 ) Next, I go through the E:\video\title.txt file and pull the title track info I need, through each iteration, to send to makemkvcon64 to extract. I store that value, each time through the loop, as %%F token variable

9) I echo the value of %%F for troubleshooting and debugging (you can REM this out if you don't need it)

10) This is the culmination of it all - from here, I call E:\video\makemkvconv64.exe and:
a) ask for an 'mkv' export type
b) and for source, I give %%A for the full path and filename for the ISO
c) I give the track identified %%F
d) and finally, I give I:\folder_name of where to put the exported MKV file identified by %%G (example I:\ABC123.iso\...

Run the batch file, make sure you have enough space on your destination drive (I:\ in my case) and go do other things.

One thing I do notice is that makemkv, based on what it finds with the "info" request in my script and output to title.txt, will create identifiers to both individual episodes as well as a whole disc track of all the episodes put together (they are the same content with one being a whole 7.5GB or so of all the episodes put together, and then individual episodes, each in their own mkv file (the latter is what I wanted). Sometimes this is easy to spot by the size of the file (i.e 7.x GB is a full DVD disk, so you would have no room for 1.5GB individual episode files that also show up when you export to MKV, so you can easily identify that large file to delete. Others, not so easy to see, so some manual surfing through the outputs/folders was required for me to clean that situation up. Other files that are 2mins to 15mins was easy to spot as being not needed here either (these would be interviews, trailers, special features, etc).

Hope this helps those looking for quick and dirty automation.