Hi guys,
I am using AviDemux to deinterlace my MPEG2 files. (Actually, they are .TOD, but Avidebux copes well with them).
I have all my *.TOD files in a 'Raw' folder. At the moment, I manually go through each file, select it, select the filters, and Save. Takes ages. Is there a script that can use that would go through a target folder, open each file, apply my deinterlace filter, and save to a destination folder?
I have no scripting experience - just hoping I can get a pointer and get started.
+ Reply to Thread
Results 1 to 5 of 5
-
-
1. Open your tod video in avidemux and set all the settings. Under File -> Save Project as a file like deinterlace.js
2. Open notepad and copy and paste all this
Code::: avidemux batch :: Edit variables (programm OUTDIR PROJECT) :: Edit to select desired file type.(line 26) :: Edit "shutdown" line for desired action :: Copy this file to directory with video to be processed and run. :: @echo off cls echo ..... Processing Video - Please Wait !! ..... echo. echo. Computer will SHUTDOWN after processing if echo. psshutdown is unremarked. echo. echo ..... Processing Video - Please Wait !! ..... SETLOCAL set programm="C:\Program Files\Avidemux 2_4\avidemux2_gtk.exe" :: Do NOT enclose OUTDIR value in quotes!That will cause format error when %OUTDIR%%%i.tod is enclosed. ("%OUTDIR%%%i.tod") becomes (""%OUTDIR%"%%i.tod") set OUTDIR=C:\folder\output\ set PROJECT="C:\folder\deinterlace.js" :: %%i and %OUTDIR%%%i.tod are enclosed with quotes because file names contain spaces for %%i in (*.tod) do ( start /w "" %programm% --nogui --load "%%i" --run %PROJECT% --save "%OUTDIR%%%i.mpg" --quit ) echo. echo. echo. ____!!Processing Complete!!____ echo. Pause ENDLOCAL
Change the OUTDIR location to a output folder where the files should be saved.
Change the PROJECT location to the deinterlace.js file you created in avidemux.
Save the file as avidemux.bat in your folder with the tod files.
Then just double click on the .bat file to run it. Or run from a command box/cmd. But try on a few files first, put the avidemux.bat and some tod file in a folder and run.
All this information can you find in the avidemux forum also. -
Thanks Baldrick!
Sorry for the delay.. never knew there was a reply.
I am using your batch file, and it's nearly working...
When I start it, I get a 'File cannot be opened' error, but when I OK that, it starts.... Working on it...
Also, it keeps processing the first file... So, the files names in output are all correct, but they contain video from the first .TOD file...Last edited by Cralis; 5th Mar 2010 at 16:26.
-
I had another Problem, which I had solved with avidemux manually.
But I too, wanted to automate this for all files in one directory.
Thaks to Baldrick - his script helped me getting the right Commands for the automatization of avidemux.
The reason for Cralis always processing the first file is, I think:
Prozessing a project, as avidemux saves it, at first loads the file which has been loaded when saving the project.
Solve this by deleting the corresponding lines (use a Text-Editor) in the project-file.
I did the same. Compare my projectfile before and after deletion.
i changed my pathes and filenames to BIG-LETTERS and
the 8 lines (Line 7 to 14) to delete are marked with 3 leading Stars ***.
The rest ist the original project as saved by avidemux.
Because of me using Linux, / ist used in a path, where \ will be used in windows.
Because of me solving another problem, the lines may look different, but I hope,
the lines to be deleted can be found with this example:
//AD <- Needed to identify//
//--automatically built--
//--Project: /PATH-OF-PROJECT/NAME-OF-PROJECT
var app = new Avidemux();
***//** Video **
***// 01 videos source
***app.load("/PATH-OF-VIDEOSOURCE/NAME-OF-VIDEOSOÄURCE");
***//01 segments
***app.clearSegments();
***app.addSegment(0,0,28496);
***app.markerA=0;
***app.markerB=28495;
//** Postproc **
app.video.setPostProc(3,3,0);
app.video.fps1000 = 25000;
//** Filters **
//** Video Codec conf **
app.video.codec("Copy", "CQ=4", "0 ");
//** Audio **
app.audio.reset();
app.audio.codec("copy",32519,0,"");
app.audio.normalizeMode=0;
app.audio.normalizeValue=0;
app.audio.delay=0;
app.audio.mixer="NONE";
app.audio.scanVbr();
app.setContainer("AVI_UNP");
setSuccess(1);
//app.Exit();
//End of script
I hope, this will help you. -
Maybe this writeup will help someone. It provides an breakdown of the basic elements of an Avidemux script.
http://bitsynthesis.com/2010/06/avidemux-basic-script-elements/
Similar Threads
-
Avidemux aspect ratio question [from newbie to Avidemux]
By ANOther1676 in forum EditingReplies: 1Last Post: 20th Jan 2012, 20:07 -
AviDemux batch script
By jakhazell in forum Newbie / General discussionsReplies: 5Last Post: 21st Aug 2011, 21:16 -
To Script or Not To Script, that is the Question... (Custom Videos)
By TheMcD in forum EditingReplies: 2Last Post: 21st Oct 2010, 10:11 -
Avidemux, script and MarkerA
By learn in forum EditingReplies: 0Last Post: 17th Feb 2010, 04:29 -
script to append numbered .avi sequence via AviDemux?
By MilesAhead in forum Video ConversionReplies: 2Last Post: 13th Jan 2010, 00:24