Log in

View Full Version : How do I demux mpeg files all at once


Stealth3si
19th August 2006, 17:57
I have a whole bunch of self-home-made mpeg files that I want to demux in its elementary streams. What program can demux all the files at once in a batch list? I already have programs that can demux but does not offer a batch list. THank you.

SeeMoreDigital
19th August 2006, 18:22
Have a look on the forum for a tool called DGIndex

Stealth3si
19th August 2006, 19:26
it only demuxes all the files into one big gigantic file. For example, all the video streams end up as one big video stream and all the audio streams end up as one big audio stream. I want it to demux each mpg file in its own separate vidoe and audio tracks.

SeeMoreDigital
19th August 2006, 19:44
Yes it does...

Click on "File" and "Save Project and Demux Video".

If I'm not mistaken, somebody on the forum has written an application to enable batch processing too!


Cheers

Stealth3si
20th August 2006, 07:42
No, it doesn't.... I just tried it.

Gehenna
20th August 2006, 10:07
This is how i would normally batch demux in DGIndex"C:\Program Files\DGIndex\DGIndex.exe" -AIF=[d:\TheXFiles-MindsEye-773314-0.mpg] -IA=3 -FO=0 -YR=1 -TN=1 -OM=1 -DRC=2 -DSD=0 -DSA=0 -OFD[D:\The X-Files - MindsEye] -exit
"C:\Program Files\DGIndex\DGIndex.exe" -AIF=[d:\TheXFiles-Drive-80838 3-0.mpg] -IA=3 -FO=0 -YR=1 -TN=1 -OM=1 -DRC=2 -DSD=0 -DSA=0 -OFD[D:\The X-Files - Drive] -exit

Just change the location of DGIndex to match where you have installed it & rename the -AIF=[my filename_inlcude path] -OFD[my target_include path] * Create target folders manually,if they do not exist.

You may need to adjust -IA=3 if your proc is not SSE2 (change -IA=2 if not)

You should end up with 3 files per 1 input mpg

Another approach is using VBS:
Set s = WScript.CreateObject("WScript.Shell")

For Each i In WScript.Arguments

cmdl = """C:\Program Files\DGIndex\DGIndex.exe"" " & " -AIF=[" & i & "] -IA=3 -FO=0 -YR=1 -TN=1 -OM=1 -DRC=2 -DSD=0 -DSA=0 -OFD[" & i & "] -exit"

s.Run cmdl, 1, true

Next

Change the location of DGIndex to suit where actually installed,
save the code as a .vbs file (ie...Demux_DGIndex.vbs)
Either create a shortcut to your desktop or use a "Send To" (C:\Documents and Settings\My Account Name\SendTo [shortcut])
Then group select files needed to be dumuxed and drag them onto the shortcut you created,or use the Send To shortcut,or just drag onto the .vbs file itself

Stealth3si
20th August 2006, 22:40
nope -- your method doesn't work either -- it doesn't continue on to the next file.

setarip_old
21st August 2006, 04:46
Hi!

You might want to try TMPGEnc. If I remember correctly there's a batch processing tool available for it at Digital Digest's site...

Gehenna
21st August 2006, 07:55
nope -- your method doesn't work either -- it doesn't continue on to the next file.

Both methods work fine.

If DGIndex window is appearing ,but no processing of video occurs,check the -AIF=[filename] for errors. (batch file version .bat)

Stealth3si
22nd August 2006, 12:36
Hi!

You might want to try TMPGEnc. If I remember correctly there's a batch processing tool available for it at Digital Digest's site... it only supports avi files..not mpegs.

Stealth3si
22nd August 2006, 12:38
Both methods work fine.

If DGIndex window is appearing ,but no processing of video occurs,check the -AIF=[filename] for errors. (batch file version .bat)again, it's being glitchy because processing does occur, the first file process fine but after that finisheds, the program doesn't exit it just sits there...

Mug Funky
22nd August 2006, 12:57
put this in a batch file:
for /R %%A in (*.m2v) do IF NOT EXIST "%~1%%~pnA.d2v" "x:\path\to\DGIndex.exe" -OM=2 -AIF=[%~1%%~pnxA] -OFD=[%~1%%~pnA] -hide -exit

this should work.

drag a folder (can be a tree of folders) onto the batch file and go away and have a coffee. when you get back you'll have a buttload of demuxed m2v's, or an error message :)

[edit]

you'll have to change the path to dgindex though... and make sure you use a later version of DGindex (this batch was written for 147b7)

Stealth3si
23rd August 2006, 04:05
nope no work either...the dos window just pops up for a few seconds and just closes... guys I appreciate all your help but what're giving me here? well anyways whatever purpose i had in mind for this project is now manually done -- don't need the automatic batch anymore.. sheesh it took longer to figure out how to automate this task for my convenience than it took me to manually do it. and we still don't know how to do it. well you got your work cut for ya. thnksa again and bye :)

snowden
27th May 2007, 01:51
for /R %%A in (*.m2v) do IF NOT EXIST "%~1%%~pnA.d2v" "x:\path\to\DGIndex.exe" -OM=2 -AIF=[%~1%%~pnxA] -OFD=[%~1%%~pnA] -hide -exit
works fine for me.
of course, you can't expect to just put this in a batch file and work magically; some manual tweaking is required.

so here's another way of making it easier to understand.

put this in a batchfile, put it in the directory that contains all the files you want to process, change the paramaters that say 'set x=y' and it should work fine for you.

set filetype=*.mpg
set dgindex=S:\VIDEO_EDIT\COMPRESSION_PACK\dgmpgdec-149\DGIndex.exe

for /R %%A in (%filetype%) do IF NOT EXIST "%~1%%~pnA.d2v" "%dgindex%" -AIF=[%~1%%~pnxA] -OF=[%~1%%~pnA] -exit

All you have to do is change the filetype to whatever you are trying to process, either .m2v or .mpg files; for most people the setting above is ok, unless you stripped the audio and video separately and are left with a bunch of .m2v files. And of course you have to set the full path to dgindex, wherever it is on your system. you don't need to change the main commandline at all (unless you know what you are doing).

If you fire up dgindex yourself you can first set all the options you want used such as the iDCT algorithm, whether you want audio stripped etc., and in options you can set a default .avs template file you want used. then when you run this batch file an .avs will be made aswell automatically with the same filename as the d2v. slick, eh? :)

olyteddy
27th May 2007, 06:40
I just found this: PVAStrumento that can de-mux mpeg2 and can run what it calls a 'jobfile'. http://www.doom9.org/index.html?/DigiTV/pvastrumento.htm

setarip_old
27th May 2007, 08:07
@Stealth3si

Based on these following posts at a different forum ( http://www.videohelp.com/forum/archive/normalizing-mp2-files-t263680.html ), it appears that you can accomplish your purpose using TMPGEnc MPEG Editor:hiwass posted 2005 Apr 16 18:19
Could you show me how to batch demultiplex them with tmpgenc editor? I went to files, mpeg tools, simple-demultiplex but it only allows me to demultiplex one file at a time. I want to load 10 files in, let it demultiplex one after the other so i don't have to sit there all day. thanks

itou_br posted 2005 Apr 18 06:58
Hiwass,

You have to add the file and use the "Batch resgister" option.
Then you can start to demux all at once. The same works for the multplex option.

smok3
27th May 2007, 09:32
this may work:
http://mpgtx.sourceforge.net/
(there seems to be windows port as well)