Log in

View Full Version : DVD2AVI FAQ draft.


hakko504
23rd February 2003, 17:54
Part 1: Versions and links

Q01: What versions of DVD2AVI are there?
A: There currently exists at least 4 under the name of DVD2AVI, one under the name of Save-OE, and one more has been hinted by Nic for ages ;) (Update: and it finally seems that it will be released) In some sort of order: DVD2AVI v1.76: Original version by jackei DVD2AVI v 1.82: Enhanced version by Ogo
DVD2AVI v1.77.3: Latest version by Jackei.
DVD2AVI v1.76 commandline version: Mod by DVD2SVCD
Save-OE: Sourceforge project, not very active. trbarry released a version of this with the name DVD2AVI 1.83.5


Q02: What's the difference between the versions and when should I use the respective versions?
A: DVD2AVI 1.76 (and commandline mod): This is the version that should be used for creating frameserver projects to use with AviSynth and vfApi. This version is usually not used at all for creating AVI's. Commandline version is required for use with some GUIs like DVD2SVCD.
DVD2AVI 1.77.3 This is a new enhanced version from Jackei that has a lot of new features and enhanced crop/resizing etc.
DVD2AVI 1.82 This was a continuation that added some useful features to DVD2AVI v1.76 when Jackei was absent and it looked like his develop+ment had stopped. This is also the basis for the Save-OE project.
DVD2AVI 1.83.5 Main reason for using this is that it is the only major version that can handle Digital TV captures, like DVB or ATSC streams. (both for frameserving and AVI conversion) It also has some nice optimizations for P4's. Should be used together with mpeg2dec2.dll

Part 2: Frameserving and projects

Q03: How does DVD2AVI relate to mpeg2dec.dll for AviSynth?
A:They are both using the same MPEG decoding engine and are both written by jackei (at least in the beginning). Mpeg2Dec.dll reads the .d2v project file from DVD2AVI v1.76 when it decodes the video into AviSynth.

Q04: Why doesn't GordianKnot/AviSynth/... accept my .d2v file?
A: Most of the times this is because you used v1.77.3 to create the .d2v. there currently is no version of mpeg2dec or vfapi that can read those files. Use DVD2AVI v1.76 instead. If you still have problems, check that no paths have changed: they are hardcoded into the .d2v file.Update: Nic's mpeg2dec3.dll v1.04 (http://forum.doom9.org/showthread.php?s=&threadid=53164) will read both v1.76 and v1.77.3 projects.

Q05: Why doesn't vfapi accept my .d2v file?
A:First see the answer of Q4. Then make sure you used video->Colorspace->RGB. It seems that vfapi reads this setting to check RGB status.

Q06: What does the first lines of the .d2v file mean?
A:Here's the start of a typical .d2vDVD2AVIProjectFile
2
45 D:\PATH\VTS_01_1.VOB
45 D:\PATH\VTS_01_2.VOB

Stream_Type=1,0,0
iDCT_Algorithm=2
YUVRGB_Scale=1
Luminance=128,0
Picture_Size=0,0,0,0,0,0
Field_Operation=0
Frame_Rate=25000
Location=0,4A2DB,0,4C401
The first line is always 'DVD2AVIProjectFile'. The second line defines the number of vobs/m2vs that are included in the project file. Then a list of the files including path. The files will here after be referenced with a number corresponding to the place in this list, so that the first file is number 0.
And the rest are some flags used for decoding the video:
Stream_Type: TBA
iDCT_Algorithm: iDCT algorithm selected in DVD2AVI. You can override this in some mpeg2dec.dll versions.
YUVRGB_Scale: PC or TV scale. PC scale uses the full 0-255 values for Y (luminance), where TV scale uses the reduced - but TV suited 16-235.
Luminance: Brightness/contrast controls I think, AFAIK not used in v1.76.
Picture_Size: crop/resize values. Not used by v1.76/mpeg2dec
Field_Operation: Defines fieldshifts or FORCE_FILM
Frame_Rate: Final framerate *1000 after Field_Operation. i.e. 23976 for FILM, 25000 for PAL, and 29970 for NTSC.
Location: used to define start and end points when you cut out a portion of the video.



Q07: What are all those numbers inside the .d2v file?
A:Some typical line of the .d2v file looks something like this:
7 0 120B 2 3 0 1 2 3 0 1 2 3 0 1 2 3
7 0 12E0 0 1 2 3 0 1 2 3 0 1 2 3 0 1
7 0 13BB 2 3 0 1 2 3 0 1 2 3 0 1 2 2
7 0 14A7 2 2 2 2 2 2 2 2 2 2 2 2 2 2
The first number is always 7, and represents a keyframe.
The second number is a reference to the filenumber, as defined in the first few lines of the .d2v. The third number is the sector offset, a reference to how far into the vob DVD2AVI/mpeg2dec should look for the keyframe (1 sector = 2048 bytes). The remaining numbers of the file is a reference to how the frames should be interpretated with reference to top/bottom-first (tff) display and repeated fields (rff).

trf = 2*tff + rff
0 0 0 (bottom first without repeated field)
1 0 1 (bottom first with repeated field)
2 1 0 (top first without repeated field)
3 1 1 (top first with repeated field)

A correctly telecined video should have the sequence ...012301230123...
A long list of 2's (or 0's) indicates interlaced video OR 25/30fps progressive.
(Thank's to Nic (http://forum.doom9.org/showthread.php?s=&threadid=49423) and neuron2 (http://forum.doom9.org/showthread.php?s=&threadid=46499) for the excellent explanations.)


Part 3: Video menu At the moment the FAQ assumes v1.76 from here on.

Q08: What is the difference between the IDCT's and which one should I use?
A:Which one to use depends on your processor: 32-bit SSE MMX is the fastest one. Requires P3 or better. This should be the default choise for most users. 64-bit floating point should be the most precise. It is very slow though. IEEE-1180 reference is inbetween the other options when it comes both to speed and quality.Most people will not be able to tell the difference in quality between these versions but you'll need some form of measuring device to find the differences. Also note that mpeg2dec3 have more CPU versions supported.

Q09: What is the field operations listed and when should I use them?
A:See the other sticky in this forum.

Q10: Which colorspace should I use?
A: RGB if you are doing to frameserve to vfapi. YUV in all other cases.

Q11: Which YUV->RGB scale should I use?
A: Rather selfexplaining: Use PC scale if you are going to mainly watch the final video on a PC, and and TV scale if you mainly are going to watch it on a TV.

Part 4: Audio menu

Q12: What's the difference between Decode and demux?
A: Decode will produce a 2 channel wav, and demux will just give you the encoded audio in MPEG2 or AC3 format.

Q13: Can I demux DTS audio in DVD2AVI?
A: Yes, in v1.77.3 only. Check this thread (http://forum.doom9.org/showthread.php?s=&threadid=43269&highlight=AVI+DTS) for info about how to handle DTS audio.

Q14: Should I process the audio in DVD2AVI at all?
A: Demuxing can be done in DVD2AVI, but this will generate a number of files called Track01.ac3 Since you need to use an IFO reading ripper anyway, why not use DVDdecrypter and do the demuxing there. It will also give you language names on the .ac3 files. Decoding and processing is better handled by BeSweet. The following questions assumes that you have decided to use the internal audio processing of DVD2AVI despite the fact that BeSweet is a better solution.

Q15: Should I check Dolby Surround downmix?
A: Leaving it unchecked will only decode the two main front channels, left and right. If it is checked, the center and surround channels will be encoded into the resulting wav file, but with 'pro logic' encoding. This may distort the audio somewhat when played back on a non pro logic capable playback system.

Q16: Should I downsample the audio from 48kHz to 44.1kHz?
A: Maybe, if you are doing (S)VCD's. Read the DVD2SCVD FAQ, Q14 (http://forum.doom9.org/showthread.php?s=&threadid=21859).

Q17: Should I normalize the audio?
A: This is usually a good idea.

Part 5: Preview Window

Q18: Why does the video seems stretched/squashed in the preview window and not show in the correct aspect ratio?
A: Because DVD2AVI's preview window does not resize the video. All DVD's store the video in 720 pixels wide and 480 (NTSC) or 576 (PAL) pixels high. For a better explanation read Doom9's article Aspect ratios explained.

Q19: What does the [ and ] buttons do?
A: They mark the start and stop for your encode/project

Q20: Why does the video jump every time I use the < > buttons?
A:Because the preview window will only display I-frames, and since they usually appear at every 12th or 15th frame, the video does indeed jump instead of moving smootly. This is also because project files need to start with a I-frame, so DVD2AVI has made it impossible to select anything but I-frames as starting points.

Q21: Why do I get green blocks all over the window?
A: You are trying to open encrypted vobs. Decryption is not built into DVD2AVI, so f.i. opening vobs directly off the DVD will not work. Usa a IFO-parsing ripper like DVDdecrypter or smartripper to get the vobs to the HD before opening them in DVD2AVI. If you have done this, check your settings in those programs or try vStrip.

Part 6: Statistics Window

Q22: What does video type (NTSC/FILM/PAL) stand for?
A: See the answer to Q09.

Q23: What does the info field tell me?
A: T: Top field first video
B: Bottom field first video
V.E.: Video Error
A.E.: Audio Error
P.E.: Picture Error or Picture type Error (printed when picture type isn't I,P or B.)
1: Numbers seems to be the normalization level for the audio.

Q23b: Do I need to know that?
A: T/B is only pure information, as is any number displayed so that can usually be ignored. T/B can be interesting if you intend to filter interlaced video in AviSynth f.i. and need to send T/B info as parameter to filter.
V.E. is more serious: that means that there is a problem decoding the picture, and may result in a lot of problems such as dropped frames, unsynched audio, blocks, etc.
A.E. Depending on what you do, A.E. will give you unsynched audio or blips in the audio, or similar. It isn't always serious, but can be quite annoying.
P.E. may result in dropped frames and unsynched audio. AFAIK it will not give blocks in the picture.

hakko504
23rd February 2003, 17:55
Note: This is a draft and it should be treated as such until otherwise stated. This means that any information is subject to change at any moment. It will not be upgraded to final until links have been added.

trbarry
23rd February 2003, 18:43
It's very hazy in my mind now but I think the save-oe source started from Ogo's never released 1.83 beta source. Maybe that was destined to be 1.84. Not sure.

There are only 2 main differences added that I'm aware of. First was some optimization, mostly for P4's. Note the speed increase is mostly irrelevant if you are frameserving with MPEG2DECx since all the heavy lifting is done later in that dll. But MPEG2DEC2.dll (YUY2, old Avisynth) and MPEG2DEC3.dll (YV12, Avisynth 2.5) also are P4 optimized with the same updates.

The other change is support for ATSC and maybe DVB digital TV streams.

No binaries are posted on the save-oe Sourceforge site but a test version the current one is usually at my site, at:

www.trbarry.com/DVD2AVIT3.zip

I'm still occasionally making updates to this and should release another one this week to deal with bad audio offsets on some HDTV channels.

The save-oe version probably should not be used on P4's unless a P4 compatible MPEG2DECx.dll is also used (MPEG2DEC2 or MPEG2DEC3). Also, no effort is currently invested in maintaining the VFAPI interface in the save-oe verson. I don't use it and so don't regression test it with my own changes.

And does anyone even remember what save-oe stands for?

- Tom

hakko504
23rd February 2003, 19:04
Thanks Tom. I hoped you'd post a comment or two. This thread (http://forum.doom9.org/showthread.php?s=&threadid=11442) defines Save-OE as Smart Audio Video Encoder - open Edition. And you're right the version I was referring to was 1.82 not 1.84. I'll change that.

trbarry
23rd February 2003, 21:16
hakko -

Good. One of the things I was going to do during this weeks bug fixes was add right click version info. And I was planning on numbering them as 1.83.xx, updating the readme files.

I've been spelunkering through fossil remains of various zip files I've kept and can somewhat create a history of readme files, etc.

- Tom

jorel
23rd February 2003, 21:55
congrats hakko504 :)

i few days i search for "dvd2avi faqs" and nothing came so
clever like your post....and i read too much links!

thank you,very good explanations!


;)

jorel
14th July 2003, 00:03
@ hakko504
:)

can you explain about dvd2avi v1.77.4 ?

thanks in advance!
;)

hakko504
15th July 2003, 21:28
Originally posted by jorel
can you explain about dvd2avi v1.77.4 ?
v1.77.3 with ability to save v1.76 projects I think. I'll edit it into the FAQ when I get back from my vacation, sometime next week most likely.

BTW, jorel, your PM box is full.

jorel
16th July 2003, 07:00
thank you very much my friend hakko504.
:)

good vacation..enjoy.
waiting for you.

ps:
tx to "talk" about my pm box too....strange,early was empty!
:)

trbarry
20th July 2003, 04:47
DVD2AVI 1.83.5 Main reason for using this is that it is the only major version that can handle Digital TV captures, like DVB or ATSC streams. (both for frameserving and AVI conversion) It also has some nice optimizations for P4's. Should be used together with mpeg2dec2.dll

I guess that would more likely be MPEG2DEC3.dll for Avisynth 2.5+ these days. And the newest and probably best MPEG2DEC3 (1.08+) version is now carried on Nic's site.

- Tom

hakko504
11th August 2003, 12:37
Ok, I have updated the FAQ to final state and reposted it in this thread (http://forum.doom9.org/showthread.php?s=&threadid=59272).