Log in

View Full Version : Running mplex in Batchmode ???


Predatore
31st May 2003, 03:05
Hello everybody ...

I'm trying to write a batch file for multiplexing mpeg2 streams because i don't want to sit all the time in front of the PC and wait till multiplexing is finished until I can start the next one :(

Now I runned into a problem.
I tried mplex form the mjpegtools to do the job for me. Well when I enter the right parameters in my command box it's doing everything fine ... as soon as I copy it into a batch file mplex refuses to work :(

Well this is my script which works in the command box but not in a batch file:

"c:\mplex.exe" -f 4 -v 1 -b 230 -V -p 1 -h -S 790 -M -o "D:\video\Ghostbusters_II_cd%d.mpg" "D:\video\Ghostbusters_II.mpv" "D:\video\Ghostbusters_II.mp2"

I already found the problem but can't find a work around. It seems as if Windows or mplex can't handle the "%d" in the output file when it reads from a batch file. Maybe Windows is doing some weird stuff with it ;)
But this "%d" is important because it counts the number of files up after mplex has arrived 790MB. But I want it to split at 790MB so it fits perfectly onto a CD-R ... :(

Anyone got an Idea or another tool which can be run from Commandline ... sadly bbmpeg doesn't work from cmd ...

Sorry for my bad English it's late ;)

jsoto
31st May 2003, 20:28
Hi Predatore,

% is interpreted by MS-DOS shell. Try escaping it with another %,
-o "D:\video\Ghostbusters_II_cd%%d.mpg". May be it works, not sure.

About bbmpeg:
dvd2svcd runs bbmpeg in command line mode. Dvd2svcd includes an executable "Runbbmpeg.exe" which does it, but, AFAIK, you have to save previously your settings in the file called "default.ini".

And, as other solution, you can write a simple script with Autoit, to launch bbmpeg.

jsoto

Predatore
31st May 2003, 23:07
Thx a lot jsoto your tip worked for me :)
I just added another % and now it runs ..... ^^

Wohooo no more waiting in front of the PC ;)