PDA

View Full Version : Batch ISO creation


Dan Miller
19th September 2008, 15:12
I'm hoping this is the right forum for this, please move it if there is a better one...

I have a drive filled with DVD file structure folders (Main folder = Movie Title, Subfolder = VIDEO_TS). I need ISOs (playable, not necessarily for burning, in other words, layer breaks aren't necessary) for all of them.

As far as I can see, IMGBURN and/or MAGICISO could do it, but one at a time. I cry when I think of that. I have 200+ movies on this drive.

Thoughts?

pc_speak
19th September 2008, 21:40
I only just now retested this on two DVD folders. YMMV.

http://www.mediafire.com/?o9jex1vlxgb

The contents of the ZIP go into the root folder of your videos. Your 'Main Folder'
-V in the batch file = Volume Identifier - max 32 characters.
So all folder names need to be, including spaces, less than 33 characters. (I have not tested this.)

Assuming a folder\file structure:

GWTW\VIDEO_TS\
3_Gorges\VIDEO_TS\
HOLIDAY_IRELAND\VIDEO_TS\
One Flew Over The Cuckoo's Nest\VIDEO_TS\
make_iso.cmd
mkisofs.doc
mkisofs.exe
mkisofs.txt
readme.1st

Double click on make_iso.cmd :)

Dan Miller
20th September 2008, 02:52
I only just now retested this on two DVD folders. YMMV.

http://www.mediafire.com/?o9jex1vlxgb

The contents of the ZIP go into the root folder of your videos. Your 'Main Folder'
-V in the batch file = Volume Identifier - max 32 characters.
So all folder names need to be, including spaces, less than 33 characters. (I have not tested this.)

Assuming a folder\file structure:

GWTW\VIDEO_TS\
3_Gorges\VIDEO_TS\
HOLIDAY_IRELAND\VIDEO_TS\
One Flew Over The Cuckoo's Nest\VIDEO_TS\
make_iso.cmd
mkisofs.doc
mkisofs.exe
mkisofs.txt
readme.1st

Double click on make_iso.cmd :)

Tried it and I see a dos window come up for a few seconds and go away... Nothing happens. Is there a way to log it?

Thanks

pc_speak
20th September 2008, 05:17
Open the batch file with notepad. Add the BOLD line to pause it.

cls
for /F "delims=" %%A in ('dir /ad/b') do "mkisofs.exe" -dvd-video -V "%%A" -o "%%~nA.iso" "%%A"
pause

pc_speak
20th September 2008, 07:37
Hi.

Better solution. I'm making it permanent for myself.

cls
for /F "delims=" %%A in ('dir /ad/b') do "mkisofs.exe" -log-file mkiso_log.txt -dvd-video -V "%%A" -o "%%~nA.iso" "%%A"

Use both techniques. Too much knowledge can't hurt. :D

Dan Miller
20th September 2008, 14:50
OK... I did the pause thing.

I have the files from the zip sitting in D:\Shares\Video\DVD (I'm using WHS). This is the folder just above the subfolders which are the rips themselves.

WHen I double click, it launches to c:\windows.

So, it is trying to make an ISO out of each of the subfolders under c:\windows, and since the MKISOFS.exe file isn't sitting in that directory, it is returning an unknown command message.

Thoughts?

pc_speak
21st September 2008, 02:02
I'm not too sure what's happening. So I set up my directory structure to match yours. :) (XP Pro)
Let's try with absolute path names. Create tmp.cmd with these two lines of code in it and double click on it.
The 1st line of code echoes the command lines to list.txt. (Post the first line from list.txt and I can see what's trying to happen.)
The 2nd line takes out the echo to list.txt and tries to execute mkisofs.exe as per usual, using absolute paths.
for /F "delims=" %%A in ('dir D:\Shares\Video\DVD /ad/b') do echo D:\Shares\Video\DVD\mkisofs.exe -log-file "D:\Shares\Video\DVD\%%~nA.log" -dvd-video -V %%A -o "%%~dpnA.iso" "%%~fA" >> list.txt
for /F "delims=" %%A in ('dir D:\Shares\Video\DVD /ad/b') do D:\Shares\Video\DVD\mkisofs.exe -log-file "D:\Shares\Video\DVD\%%~nA.log" -dvd-video -V %%A -o "%%~dpnA.iso" "%%~fA"
This is my list.txt
D:\Shares\Video\DVD\mkisofs.exe -log-file "D:\Shares\Video\DVD\IRELAND_HOLIDAY.log" -dvd-video -V IRELAND_HOLIDAY -o "D:\Shares\Video\DVD\IRELAND_HOLIDAY.iso" "D:\Shares\Video\DVD\IRELAND_HOLIDAY"
D:\Shares\Video\DVD\mkisofs.exe -log-file "D:\Shares\Video\DVD\The_3_Gorges.log" -dvd-video -V The_3_Gorges -o "D:\Shares\Video\DVD\The_3_Gorges.iso" "D:\Shares\Video\DVD\The_3_Gorges"


Isn't this fun? :)

RunningSkittle
21st September 2008, 03:01
set dir=""
set dest=""


Would be useful in this kind of script

RunningSkittle
21st September 2008, 03:52
My attempt, same commands i guess


@echo off
color 0a
title makeiso

set dir="c:\test"
set dest=c:\iso
set makeiso="c:\test\mkisofs.exe"
mkdir %dest%


for /d %%a in (%dir%\*) do echo %makeiso% -log-file "%dest%\%%~na-log.txt" -dvd-video -V "%%a" -o "%dest%\%%~na.iso" "%%a" >> "%dest%\cli-log.txt"
for /d %%a in (%dir%\*) do %makeiso% -log-file "%dest%\%%~na-log.txt" -dvd-video -V "%%a" -o "%dest%\%%~na.iso" "%%a"

pause
:end


It seemed silly to rely on parsing to enumerate directory names :)

Chetwood
21st September 2008, 11:02
Well, if you guys should need Layer Breaks everntually and do come up with a solution please let me know. I've suggested ImgBurn to automatically select a layer break from the index but LUK has so far only added this


2.4.1.0
* Added: Saving a project file now writes the previously selected LB info from the 'Create Layer Break' window. This can then be used when loading the IBB via CLI so the user isn't prompted to pick a LB, thus allowing for batch builds.

which does let you build ISOs by command line but still requires you to open each folder in advance to set the layer break.

Dan Miller
21st September 2008, 17:16
which does let you build ISOs by command line but still requires you to open each folder in advance to set the layer break.

Can you give me an example of the cammand line syntax to do the batch build?

Chetwood
21st September 2008, 17:55
Haven't tried myself yet due to the lack of said function. Just check the readme.txt or the ImgBurn forums. While you're over there try to rally up enough people to support my suggestion (http://forum.imgburn.com/index.php?showtopic=6252&hl=) from March 2008 which would allow for completely automated batch building once implemented.