|
What is the best way to get MPEG2-files ready to be operated within VirtualDub ?
There is definitely not only one way to do. Probably you have already tested - like
me - a lot of applications for file conversion, sound extraction and so on. One solution is described now as a little tutorial (you will also find this as an example macro-set in your 1to5 FileProcessor installation, you just
need to correct the path names to your need):

The job is to prepare a mpg2-video file for avi-streaming output, extract audio from the file, convert it to a wav-file, open VirtualDub, load the avi and the wav and correct the audio time delay.
The following applications will be used: DVD2AVI, VFAPI, MP3DECODE and VIRTUALDUB Converting a 2h video recording will take only about 2...5 min.
Before defining the macros, please make sure that all these applications are installed properly and work on your PC. Open 1to5 FileProcessor...
Now open the Main Input window by clicking the folder icon on the right.
Choose the Mpeg2ToVirtualDub example macro-set. Then close the Main Input window. Now open, one after the other, the application and macro definitions by just clicking one of the four application-label areas....
Adjust all application and folder definitions according to your system. When done, 1to5 FileProcessor is ready to go. Close the macro window and press the first “Run Macro” button.
Since 1to5 FileProcessor monitors opening windows and pull-ups, please do not disturb the macro operation by launching other applications or by activating any passive window, wait for the “Ready” signal.
|
|
Which macro commands can be used and how is the syntax defined ?
The user-macro area starts after the SET... area, the SET... commands are generated
automatically when saving a set-up. The user commands are currently the following:
Commands:
WAIT_FOR_MAINWINDOW Waits max. 60s for active main window of the application launched by the macro WAIT_FOR_ANYPOPUP Waits max. 60s for any active popup window opening WAIT_FOR_WINDOW String Waits for active window, where the title line includes String
POS_MAIN_WINDOW Top Left Width Height Changes the position and dimensions of the main application window. Top...Height are numbers. CLOSE_EXE Closes the main application CLOSE_1TO5 Closes 1to5 FileProcessor WAIT_FOR_DISK [VARx]
Waits for inactivity of the disk drive defined in [VARx]. All vars can be used. MOUSE_CLICK x y Left clicks at x,y relative to the currently active window
SEND_KEYS [VARx] Sends characters in variable [VARx] as keystrokes to the active window. All vars can be used.
[VARx]=[VARy]+”Text” Transfers the content of [VARy] with “Text” appended to [VARx] [VARx]=Function [VARy] Transfers a function (see below) value to variable [VARx]
‘ comment text All characters after the comment sign ‘ are ignored as user comment <Pause> Delays the macro operation for 500ms
Available functions:
FIND_FILE [VARx] Retrieves the file name(s) after searching the directory defined in [VARx]. [VARx] should
contain something like “C:\Data\*.dat”. If you use the editable path variables [INP1]....[OUT3] the file search extention is taken from the according fields next right of them.
GET_VFAPI_AUDIO_DELAY [VARx] Extracts the time delay information from the file name string in [VARx] as number string.
For example if the file name is “HalloWeen H20 MPA T01 DELAY -160ms.mpa” the result is “-160”.
All other characters are send as keystrokes directly to the active window !
If you need to send special characters, you may choose from the following list:
<Shift+> and <Shift-> sets and resets the shift key permanently. <Alt-x> sends the combination Alt-x <Ctl-x> sends the combination Ctl-x <F1>....<F12> function keys
<Ret> Enter key <Esc> Escape key <Tab> <Shift-Tab> Tabulator keys <Left> <Right> <Up> <Down> <Home> <End> <PgUp> <PgDn> <Ins> <Del>
Variables:
The most of the input fields are directly accessible by their variable name, like [INP1], [OUT3], [INP1EXT], [PROJECT], [INPF]..... Additionally the three internal vars [VAR1],[VAR2] and [VAR3] are useable for your purpose. All variables are handled as string variables internally.
|
|