PDA

View Full Version : jobs file documentation ?


ikarus
16th May 2003, 09:49
Hi,

after reading the virtualdub-docs, and searching this board
without finding what i was looking for, i decided to ask here. I'm not sure if this possibly belongs to the codecs section, but basically it´s a vdub issue:

Let me explain in long:
I´m doing alot of TV-Recording, and encode to divx3 / xvid (each 2 pass). ATM Nandub gives me the comfort of only hitting the two pass button while vdub/xvid requires me to click around alot.

so i thought to myself, why not write a little script (for me some serious challenge;)), that would create a virtualDub jobs file from my (slightly extended) .avs files.

so i took a look at the jobs file, and found it was plain text, human readable except the part where the codec comes into play.
there it gets cryptic, the codec settings are a long row of numbers and letters.
i suppose theres some interval this row is parsed for specific settings. Changing the desired size in the xvid dialouge alters some letters in the job file but leaving others untouched supports that idea i think (as well as does logic i suppose)

so, since testing all combinations would be quite lenghthy, maybe someone reading this could give me a hint on how this string is set up, what index of letters is for what setting , or maybe simpler things like how is the desired size in "normal" numbers converted (is it to hex ? some other format ?) i no math genius but i think some toss to the right direction will help alot.

thanks for reading this rather lenghty post
and TIA for any answer, hint, link or other help

ikarus

jonny
16th May 2003, 12:28
The codec data is encoded in base64, you can find more searching in the Development forum for base*64 or mime*64.
Once you decode it, it's not hard to find codec parameters making some compares (for the codec data format, it will be faster to take a look on XviD's sources if you are going to use it)

ikarus
19th May 2003, 21:14
thanks for the hint towards base64, seems to be right, i took the string from my jobs file,

--job file--------
VirtualDub.video.SetCompData(1140,"BQAAAKC7DQDsAQMAXHZpZGVvLnN0YXRzAABzAHQAYQB0AHMAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA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AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAUAAAAFAAAABAnAAAQJwAAdwAAAAAAAAABAAAA");
VirtualDub.video.filters.Clear();
--------------

put it into a
--------------.txt file -------------
BQAAAKC7DQDsAQMAXHZpZGVvLnN0YXRzAABzAHQAYQB0AHMAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABVAAAABQAAABAAAABkAAAAZAAAAAUAAAAEAAAAAAAAACwBAAABAAAAAAAAAAAAAAAAAAAAAgAAABAAAAACAAAACAAAAAgREhMVFxkbERITFRcZGxwUFRYXGBocHhUWFxgaHB4gFhcYGhweICMXGBocHiAjJhkaHB4gIyYpGxweICMmKS0QERITFBUWFxESExQVFhcYEhMUFRYXGBkTFBUWFxgaGxQVFhcZGhscFRYXGBobHB4WFxgaGxweHxcYGRscHh8hAAAAAAoAAAAeAAAAAQAAAAAAAAAZAAAACgAAAAEAAAABAAAAHgAAAAEAAAAyAAAAAQAAAPQBAABaAAAAMgAAAICWmAA8AAAAPAAAAPoAAAABAAAAAQAAAFxoaW50ZmlsZS5tdmgAbABlAC4AbQB2AGgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAXHZpZGVvZ2suc3RhdHMAAC4AcwB0AGEAdABzAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAUAAAAFAAAABAnAAAQJwAAdwAAAAAAAAABAAAA
-----------------------
and decoded it:

-----decoded file ---
 _»
ì \video.stats s t a t s U   d d   ,        # #& #&) #&)-!
  
    2  ô Z 2 €–˜ < < ú   \hintfile.mvh l e . m v h \videogk.stats . s t a t s    ' ' w 
-----------------

well, needles to say i cannot really use that information.
i also tried the xvid documentation, but since i am not a programmer / computer science student i cannot really read any information from that comprehensive documentation that would help me in my task.

I' d be very grateful if someone could give me another hint or explanation how to find the settings for the codec in that string.

it seems xvid itself encodes its settings again before vdub applies its base64 encoding. but as mentioned that xvid doc is far too sophisticated for me to understand.

so any advice from insiders would be welcome.
i am aware this tread spans over vdub/xvid/developement, so if any moderator thinks the thread is inappropriate here, just move it to the section you think it fits best.

thanks in advance
ikarus

jonny
19th May 2003, 21:49
Yep, after decoding it, the info are in binary format (i was thinking you are a programmer, but yes, it's difficult to manage it if you aren't).
As you can see, you can easy find the strings for the log files.

You can consider the decoded data as a sequence of numbers (bytes). Each byte have a value that range from 0 to 255.
The main part of the parameters are stored in DWORDS (so a sequence of 4 bytes).
2 bytes give a number from 0 to 65536, 4 bytes give a number from 0 to 4GB.

You can take a look at this opening the raw data in a binary editor (you'll notice that changing for example the encoding mode will change one of the values in the data).

I dunno if there is a good binary editor that pack and shows DWORD values (usually you are able to see only single bytes values with a binary editor)... any suggestion is welcome here :)