View Full Version : DVD2AVIdg/MPEG2DEC3dg Version 1.2.0
I've cut loose version 1.2.0 release candidate:
http://neuron2.net/fixd2v/decodefix120RC7.zip
EDIT: I updated this post to point to the latest build.
zettai
1st May 2004, 08:10
Great work!
One thing I'm interested in (as you know) is this chroma upsampling issue. I notice you've fixed it for vfapi.
With mpeg2dec, the problem could be similarly fixed if it were possible to ask for YUY2 or RGB footage directly from mpeg2dec. Equally it would be useful to provide an IsCombed-like hint which could be read by conditionalreader or possibly the colourspace covertion filters in future versions of Avisynth.
Are either of these approaches possible?
@zettai
Did you see my posting in Avisynth Usage? I'm mulling that over right now. Of course it is all possible. I want to assess the practical significance before I prioritize my work.
What do you think is the most important next step for DVD2AVIdg/MPEG2DEC3dg?
zettai
1st May 2004, 16:09
Yeah, I saw that post after this one.
I don't see a huge benefit at the moment of doing the conversion in mpeg2dec given that you will only be porting to avisynth and the conversion could be done just as easily there.
I'd be perfectly happy with just a conditional hint being sent - that would at least provide a fix for the problem. Anything else could come later, I suppose.
I agree. I will modify the conversion filters included in MPEG2DEC3dg to read the hint, and I will document the hint so that other filters can use it.
stax76
1st May 2004, 18:04
it's great you are working on DVD2AVI. I have two request, commas in source file names don't work with the commandline:
-Input-Files -IF ([file1,file2,file3,......])
captures often have commas. Maybe you could change the dll/exe name to the original names to prevent users from duplicates. I would like to send you a patch but I'm not sure I'm far enough with my C++ tutorial:(
Originally posted by Dolemite
I have two request, commas in source file names don't work with the commandline:
-Input-Files -IF ([file1,file2,file3,......])
captures often have commas. I don't want to break the existing clients.
Maybe you could change the dll/exe name to the original names to prevent users from duplicates. I don't understand your request.
stax76
1st May 2004, 19:03
let's assume you've two files capture,0.mpg and capture,1.mpg, it's not possible to open it with the cli because comma is used as delimiter instead of checking quotation marks plus comma (regex: " *, *") as delimiter before.
some users might copy MPEG2Dec3dg.dll to the AviSynth plugin directory and forget to remove MPEG2Dec3.dll. Changing it would also make it easier to deploy it with tools like DVX and Gordian Knot and a version like 1.0.0.0 that can be read with the API to ensure it's the proper version but I don't want to bother you with that things
Originally posted by Dolemite
let's assume you've two files capture,0.mpg and capture,1.mpg, it's not possible to open it with the cli because comma is used as delimiter instead of checking quotation marks plus comma (regex: " *, *") as delimiter before. I understand your point but the existing clients use the comma as a file list delimiter. If you can convince them to modify their syntax...
Dark-Cracker
1st May 2004, 20:13
some tools use the command line of dvd2avi but i think if u change the command line function in your next dvd2avi v1.2 the authors of these tools will read the changelog and made the necessary changes in their software to assume 100% compatibility with your new command line. i am sure all the people who use dvd2aviCLI will be happy to see this nasty bug have been corrected.
generaly when u release a new version this mean some new functions i think the fact the command line change, will not annoy the developpers who use dvd2avi.
>I understand your point but the existing clients use the comma as a file list delimiter.
the comma is allowed in the foder/file name it's foolish to use it as delimiter.
plz plz plz erase this annoying bug :)
zettai
1st May 2004, 20:24
I don't see why you just can't avoid putting a comma in your file...
stax76
1st May 2004, 20:28
you could implement it like this: if there are quotation marks use '","' as delimiter otherwise use the current method. Another suggestion would be supporting the windows shell. The windows shell uses a blank as delimiter and quotes only if the path has blanks. Windows shell is things like somebody put a link to DVD2AVI under "Send To" and send file(s!) to it or somebody use a context menu editor ("...DVD2AVI.exe" "%1"), "Open With", D&D etc.
Suggest a delimiter character that is not a valid filename character and not interpreted by the command shell. Thank you.
stax76
1st May 2004, 21:10
pipe (|)
Cyberia
1st May 2004, 21:16
Why not just require a file list? I realize it breaks compatibility, but it would fix this issue and shorten the command line when more than one file is used.
Cyberia
1st May 2004, 21:16
Suggest a delimiter character that is not a valid filename character and not interpreted by the command shell. Thank you.
Maybe a colon ":"
Dolemite, pipe is a shell character.
Cyberia, you mean a text file list?
: is a valid path character, e.g., c:\file
Cyberia
1st May 2004, 21:57
Cyberia, you mean a text file list?
Yep. You could generate one easily by using a command like:
dir *.vob /b /od >dvd2avi.lst
or you could even provide a GUI option to generate a list.
Cyberia
1st May 2004, 21:59
You could still use a colon by requiring just the filenames. All paths would then be required to reference files in the current folder.
I was going to suggest using local references to the files anyway. I often rename folders and when I do I usually have to re-generate the d2v files because they no longer work.
stax76
1st May 2004, 22:26
I would prefer a commandline always over config file, full windows shell support requires commandline anyway
See, Dolemite, I have too little time to spend it rewriting the parsing code for such a minor issue. The only viable option would be to replace the comma with something else. Maybe the + sign?
Moitah
2nd May 2004, 02:33
Originally posted by neuron2
Maybe the + sign? I believe that is allowed in filenames. How about a question mark ("?")?
Cyberia
2nd May 2004, 02:54
It's not hard to rename files...
stax76
2nd May 2004, 03:04
I would love to do some cli research and rewrite it but unfortunately like stated already I'm not that far with my C++ tutorials. I totally skipped any DOS tutorials (does pipe mean Or in DOS?) so I'm also not the best candidate to suggest a better delimiter:(
? is a shell wildcard.
Does anybody ever see + signs in filenames?
EDIT: Umm, "Visual C++". :scared:
Cyberia
2nd May 2004, 07:18
doesn't + mean concatenate?
Here's a release candidate for Version 1.2.0.
http://neuron2.net/fixd2v/decodefix120RC1.zip
It adds these new changes compared to 1.2.0beta1:
* Changed marking to be like VirtualDub. You can always set
a new start or end point.
* Added a test for MPEG1 files. Pop up a warning box and
prevent decoding when an MPEG1 file is loaded.
* Added a new field operation mode: 3 = Raw Encoded Frames.
This mode suppresses pulldown and delivers the raw encoded frames.
It differs from Force Film in that no frames are added or
deleted (to maintain film rate) and the frame rate is
left at its coded value. The RFF flags are also stripped
away in the D2V file.
Cyberia
2nd May 2004, 20:20
* Added a new field operation mode: 3 = Raw Encoded Frames.
How is this different from field operation (NONE)?
vispgraedde
2nd May 2004, 23:40
I believe that's a feature for hybrid streams, so that you can get both progressive and interlaced frames from the same d2v. Kinda like a mixed forcefilm/none mode?
vispgraedde
3rd May 2004, 00:24
I tried this new feature with a hybrid encode I have...
And parsed the d2v with parsed2v...
But... How do I now convert the results to frameranges where the output frames are progressive and interlaced respectively?
Especially with output like the following throughout the whole logfile.
[GOP START]
192: 192,192 -- 0 [vob/cell=0/0] [3:2 pattern break]
193: 193,193 -- 2 [vob/cell=0/0] [3:2 pattern break] [ILLEGAL TRANSITION!]
194: 194,194 -- 2 [vob/cell=0/0] [3:2 pattern break]
195: 195,195 -- 0 [vob/cell=0/0] [3:2 pattern break] [ILLEGAL TRANSITION!]
196: 196,196 -- 0 [vob/cell=0/0] [3:2 pattern break]
197: 197,197 -- 2 [vob/cell=0/0] [3:2 pattern break] [ILLEGAL TRANSITION!]
198: 198,198 -- 2 [vob/cell=0/0] [3:2 pattern break]
199: 199,199 -- 0 [vob/cell=0/0] [3:2 pattern break] [ILLEGAL TRANSITION!]
200: 200,200 -- 0 [vob/cell=0/0] [3:2 pattern break]
201: 201,201 -- 0 [vob/cell=0/0] [3:2 pattern break]
202: 202,202 -- 0 [vob/cell=0/0] [3:2 pattern break]
203: 203,203 -- 0 [vob/cell=0/0] [3:2 pattern break]
[GOP START]
204: 204,204 -- 0 [vob/cell=0/0] [3:2 pattern break]
205: 205,205 -- 0 [vob/cell=0/0] [3:2 pattern break]
206: 206,206 -- 0 [vob/cell=0/0] [3:2 pattern break]
207: 207,207 -- 0 [vob/cell=0/0] [3:2 pattern break]
208: 208,208 -- 0 [vob/cell=0/0] [3:2 pattern break]
209: 209,209 -- 0 [vob/cell=0/0] [3:2 pattern break]
210: 210,210 -- 0 [vob/cell=0/0] [3:2 pattern break]
211: 211,211 -- 0 [vob/cell=0/0] [3:2 pattern break]
212: 212,212 -- 0 [vob/cell=0/0] [3:2 pattern break]
213: 213,213 -- 0 [vob/cell=0/0] [3:2 pattern break]
214: 214,214 -- 0 [vob/cell=0/0] [3:2 pattern break]
215: 215,215 -- 0 [vob/cell=0/0] [3:2 pattern break]
[GOP START]
216: 216,216 -- 2 [vob/cell=0/0] [3:2 pattern break] [ILLEGAL TRANSITION!]
217: 217,217 -- 0 [vob/cell=0/0] [3:2 pattern break] [ILLEGAL TRANSITION!]
218: 218,218 -- 2 [vob/cell=0/0] [3:2 pattern break] [ILLEGAL TRANSITION!]
219: 219,219 -- 0 [vob/cell=0/0] [3:2 pattern break] [ILLEGAL TRANSITION!]
220: 220,220 -- 2 [vob/cell=0/0] [3:2 pattern break] [ILLEGAL TRANSITION!]
221: 221,221 -- 0 [vob/cell=0/0] [3:2 pattern break] [ILLEGAL TRANSITION!]
222: 222,222 -- 2 [vob/cell=0/0] [3:2 pattern break] [ILLEGAL TRANSITION!]
223: 223,223 -- 0 [vob/cell=0/0] [3:2 pattern break] [ILLEGAL TRANSITION!]
224: 224,224 -- 2 [vob/cell=0/0] [3:2 pattern break] [ILLEGAL TRANSITION!]
225: 225,225 -- 0 [vob/cell=0/0] [3:2 pattern break] [ILLEGAL TRANSITION!]
226: 226,226 -- 2 [vob/cell=0/0] [3:2 pattern break] [ILLEGAL TRANSITION!]
227: 227,227 -- 0 [vob/cell=0/0] [3:2 pattern break] [ILLEGAL TRANSITION!]
Originally posted by Cyberia
How is this different from field operation (NONE)? Didn't you read the changes text file?
Originally posted by vispgraedde
But... How do I now convert the results to frameranges where the output frames are progressive and interlaced respectively?
Especially with output like the following throughout the whole logfile.
[GOP START]
192: 192,192 -- 0 [vob/cell=0/0] [3:2 pattern break]
193: 193,193 -- 2 [vob/cell=0/0] [3:2 pattern break] [ILLEGAL TRANSITION!] Choke. :scared:
You see, uh, this is why we have betas, isn't it?
I shouldn't strip the RFFs from the D2V, but rather just have them be ignored.
Thanks friend, I'll fix that. But right now...it's time for Sopranos!
vispgraedde
3rd May 2004, 02:51
Originally posted by neuron2
Choke. :scared:
:D
You see, uh, this is why we have betas, isn't it?
I shouldn't strip the RFFs from the D2V, but rather just have them be ignored.
Thanks friend, I'll fix that. But right now...it's time for Sopranos!
I figured I should test and report on this feature since I am one of the (few?) people that would find this feature interesting :p
This brings up a little feature addition for ParseD2V... how about an option to it that can output avisynth style ranges so you can see more easily what sequence is supposed to be 24 and what are 30?
Monamona
3rd May 2004, 17:12
Thank you for the great job Donald!
Well, When I load more than one VOB files at one time, the audio
loses sync after the second VOB. The reason seems to be that, when
DVD2AVI loads VOBs, it calculates audio delay for the first VOB and
applies to each other VOB.
Say, audio of the first VOB has -66ms delay, DVD2AVI loads the
audio of the second VOB with additional -66ms delay, which is not
necessary. For the third VOB, the delay becomes -132ms.
But this audio asynchronization is not big, so it might be hard to
realize.
It happens when I make project file(d2v) and demux mpa(mp2) and AC3
from VOB. But I believe it also happens when I choose the option to
decode to wav. To merge VOBs by some other soft before processing on
DVD2AVI does not solve this problem.
Could you also fix this, Donald?
I am sory fot the bad explanation.
Regards
Trahald
3rd May 2004, 18:25
Originally posted by vispgraedde
:D
I figured I should test and report on this feature since I am one of the (few?) people that would find this feature interesting :p
Include me in. RB pointed this thread out to me (thanks). Great work dg
I'll play (lack of a better term) with raw mode when i get some time.
>I'll play (lack of a better term) with raw mode when i get some time.
Wait for my next release tonight before you start playing with it. Raw mode has two bugs that need fixing.
Here is RC2: http://neuron2.net/fixd2v/decodefix120RC2.zip
The changes from RC1 are:
11. Added a new field operation mode: 3 = Raw Encoded Frames.
This mode suppresses pulldown and delivers the raw encoded frames.
It differs from Force Film in that no frames are added or
deleted (to maintain film rate) and the frame rate is
left at its coded value. The RFF flags are left intact in
the D2V file but they are ignored during decoding.
12. If the picture size is greater than 1024x768, the display
window is zoomed out by a factor of two (preparing for HDTV
and transport stream support).
13. The Save AVI menu option was deleted.
14. The Local Language menu option was deleted.
15. The Color Space menu option was deleted. Without Save AVI,
it served no purpose. The corresponding -CS command line option
was also removed.
16. The Display and Information menu "options" were removed as
they appeared to serve no useful purpose.
Cyberia
4th May 2004, 02:10
What exactly does the 'Process WAV' command do?
Originally posted by Cyberia
What exactly does the 'Process WAV' command do? From jackei's web page:
"This function performs 48->44.1KHz, Normalization, and Delay Compensation at once for multiple WAVs.
Before processing WAV, you must decide the details of 48->44.1KHz and Normalization at first."
(You will be prompted for the delay compensation value.)
EDIT: Cyb, what is your personal next most-wanted enhancement?
vispgraedde
4th May 2004, 03:01
No illegal transitions out of ParseD2V this time ;)
So now I look at the output and try to understand how to read it to create the ranges that I am interested in.
At first I thought f: a,b -- q [blabla] meant that it was interlaced if a=b, but then I saw [3:2 pattern break]'s
0: 0,0 -- 2 [vob/cell=0/0]
1: 1,1 -- 2 [vob/cell=0/0] [3:2 pattern break]
2: 2,2 -- 2 [vob/cell=0/0] [3:2 pattern break]
3: 3,3 -- 2 [vob/cell=0/0] [3:2 pattern break]
so I guess I was wrong...
I did not see anything in the included docs about how to interpret the output for the purpose of figuring out what framerange is progressive and which are interlaced, based on the output from ParseD2V (or maybe the d2v directly).
Since the thing I am working on currently have a ****load of transitions between progressive and interlace, I was going to write a program or script to help me, but for that I would need to know exactly how to interpret the data.
Can anyone point me to the "missing" documentation?
Cyberia
4th May 2004, 03:09
Oh I don't know. Most of them don't seem too hard. Audio might be nice.
I do have a question though. Would people mind removing the Downsampling/DRC/Normalization completely?
Enhancement 4 refers to replacing this code with the BeSweet equivalent, but why not just use BeSweet itself. I'd say offer ONLY demuxing options.
BTW: now that the SaveAVI is gone, we really need a new name!
Originally posted by Cyberia
BTW: now that the SaveAVI is gone, we really need a new name! Yeah, I've been thinking about it. Here's my proposal.
Using "TMPGEnc" as a template, I will have the entire package named as DGMPGDec. I don't put a 2 in there because it will support MPEG1 eventually. DGMPEGDec will consist of several components:
DGParse.exe (was DVD2AVIdg)
DGDecode.dll (was MPEG2DEC3dg)
DGVFAPI.vfp (was VFAPIdg)
ParseD2V and FixD2V will be integrated into
DGParse and invokable through the menus.
I'm thinking of dropping legacy 1.76 D2V support. Who needs it and why? Then the index file format may change dramatically.
Originally posted by vispgraedde
I did not see anything in the included docs about how to interpret the output for the purpose of figuring out what framerange is progressive and which are interlaced, based on the output from ParseD2V (or maybe the d2v directly).
Since the thing I am working on currently have a ****load of transitions between progressive and interlace, I was going to write a program or script to help me, but for that I would need to know exactly how to interpret the data.
Can anyone point me to the "missing" documentation? Let's define some terms first as you are not clear on your requirements: A frame can be "really" interlaced or progressive. Then it can be MPEG encoded as interlaced or progressive. It makes sense to have the two match but they don't always match due to bad encoding. Also you can have hard telecining such that there are interlaced frames but they can be field matched back to progressive.
Then there are sequences of frames that use pulldown and those that do not. We might call them film and video but that would not be strictly correct because you can have non-film patterns of pulldown (RFFs can be arbitrarily set as long as the display fields continue to alternate top and bottom).
I won't try to guess what you are after but please post again and explain given this explanatory framework.
I can say that the best we can do is to extract from the stream the relevant flags and make them available in the D2V. Those flags are the progressive/interlaced flag and the TFF/RFF. The TFF/RFF is currently there. We could add the progressive/interlaced flag. But remember it is not always reliable.
My primary goal with this feature was to assist analysis of video by enabling inspection of the actual encoded pictures. It may be that we can use it for your purposes as well.
Cyberia
4th May 2004, 03:49
Hey I was thinking about the drag-n-drop ordering issue, and realized this: They are almost certainly chronologically ordered already. The ripping programs creates them sequentially, so you really don't need to parse the filename, just check the timestamp. It's a hack but it will work 95%+.
Another alternative would be to put a "Move Up" and "Move Down" button on the open dialog, to manually reorder the files.
Trahald
4th May 2004, 04:51
Thanx for the updated release.
What I'm looking at doing is trying to recreate hybrid material exactly as the origional. this will require a special pulldown but should be doable.
obviously it may not be the best thing to do in some situations (where there is lots of encoded telecine) but for automations sake and to not sacrifice the pure video around the hard telecine, it would make life easier.
vispgraedde
4th May 2004, 04:56
Ok. Here is the thing I'm working with.
The source contains both 24fps FILM with pulldown flags, as well as 24->30fps "hard telecined" Video, possibly some "clean" 30fps parts as well, but it's an old movie so I doubt it.
What I want is to get the FILM frames clean w/o the pulldown, and the rest as they are encoded so that I can do manual ivtc on only them. Not having to bother ivtcing the FILM parts.
Knowing what output frameranges are FILM and which are encoded as Video would make this possible (I think).
I'm here assuming that the flags are correctly set throughout.
My reason for not just using decomb is that I can't find any single setting that work good throughout, and using overrides is (for me) supoptimal since I then have to go through the whole source and look at all frames to figure out where I need overrides. And if I have to look at all frames, I might as well do this in a manner that I find easier (using TMPGEnc).
I hope that explains better what it is I ask for.
Originally posted by vispgraedde
I hope that explains better what it is I ask for. Perfectly. And that makes things easy. All you have to do is look for the pattern break indication. A film sequence is a sequence of frames without the pattern break indication. E.g.:
0
1
2
3
4 [break]
5 [break]
6 [break]
7
8
9
10
Here, 0-3 and 7-10 are film and 4-6 are non-film (using your definition). In practice you might like to enforce something like this: a sequence of more than 5 frames without any breaks is film.
Be careful to properly distinguish encoded frame numbers from display frame numbers.
(For hard telecining, you can use Telecide's debug output log to see which frames are considered "in-pattern".)
ADDENDUM: A film sequence will have the flag bytes repeating this pattern 0 1 2 3 0 1 2 3 ... When you see [3:2 pattern break] it just means that the frame doesn't follow this pattern compared to the previous frame. So if you have 1 and then a 3 it's a break because it should have been a 2.
vispgraedde
4th May 2004, 13:49
Thanks. That makes things a little easier for me :)
Keep up the good work.
Moitah
4th May 2004, 22:09
I have a video where seeking is terribly broken (in 1.2.0RC2 and 1.1.0). It was captured with a DVB card. Let me know if you need me to upload it somewhere. Here's a screenshot:
http://members.cox.net/moitah/jojoseek.jpg
Again, this is only when seeking, regular playback works fine.
EDIT: I get the "Opening GOP is not closed" warning, but seeking anywhere throughout the video doesn't work properly.
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.