Log in

View Full Version : MPEG2AVI : which iDCT should i use?


palesi
1st April 2002, 16:03
Since there's no place in this forum for MPEG2AVI questions i thought it would be appropriate to post it here.

I'm using MPEG2AVI PX3/OGO 0.1.5d (the latest version AFAIK) and i'm a bit confused about the various iDCT choices. Most of the guides that i've read suggest to use the 16-bit MMX Chen iDCT (-r2) because the 32-bit MMX iDCT (-r1) is buggy/broken : is that true even with the latest version ? Isn't the 32-bit version better?
What about the 64-bit Floating Point iDCT (-r0) ?

And, let's say i have an Athlon or a Pentium-III, shouldn't i benefit from -r4 and -r5 ?

I'd ignore the 64-bit FPU IDCT (-r7) since it's painfully slow, it gives no real quality improvement and maybe it's even buggy : http://arbor.ee.ntu.edu.tw/~jackei/dvd2avi/refidct/

Do any of you geeks have a clue :) ?

Please reply. Tnx.

DJ Bobo
1st April 2002, 17:28
I don't have this program, but I will compare with DVD2AVI.
In DVD2AVI there is 3 possibilities:

32-bit MMX SSE: fastest setting, in theory the worst quality, but I always use it since I don't see a worse quality! I have a PIII

64-bit Floating Point: only 3% slower than 32-bit, in theory better quality than 32-bit

Reference iDCT: slowest setting (I've never used it, so I can't tell you how slow it really is), in theory best quality

Amerzone
1st April 2002, 20:50
I am still using mpeg2avi (same version, as yourself) and I always use the -r1 switch (32-bit mmx idct). I encode @ high bitrates (2cd) with a resolution of 640 x yyy and the result is always awesome. Btw, I'm using the nice simple_frontend gui of chi for automatic DivX4 2-pass encode. If you want this nice tool, just let me know (amerzone@myrealbox.com)

auldarstarglade
2nd April 2002, 03:05
I have been wanting a good answer to this question myself.

I've spent a bit of time encoding with m2apx3g (mpeg2avi px3 ogo version), and played with these settings.

I have an Athlon 1.3ghz, and I found no discernable difference in encoding speed or encoding quality when using r1 or r4. I use r4 now just as a matter of course since I do use an Athlon. I have to say I haven't used Divx5 yet, however the release stated that it would now properly support Athlon CPU's, which may mean that selecting r4 may make a significant difference now.

Anyone tried r4 with an Athlon CPU with divx 5?

palesi
2nd April 2002, 13:22
I have to say I haven't used Divx5 yet, however the release stated that it would now properly support Athlon CPU's, which may mean that selecting r4 may make a significant difference now.

I don't think that the iDCT setting could influence the codec's speed, as it should deal only with decoding MPEG2 content (correct me if i'm wrong).

So, it seems i could safely stick to the -r1 setting...

Amerzone
2nd April 2002, 20:06
Btw, since we're talking about m2a, is there any new version of DivXauto that works with the DivX 5 pro codec? I found something at divx-digest, but frankly speaking I don't know how I could use it in a batch file with m2a. And what about auto 2-pass encoding in m2a?

auldarstarglade
3rd April 2002, 05:22
If you visit:

http://easydivx.does.it

You can download the latest version of Easydivx which has support for Divx 5. I assume it also has a new version of divxauto.

Easydivx is a rather easy front-end that combines various utilities to make divx encoding easy. It uses vstrip, m2a to do the encoding, audiodec avimux etc etc.

Personally I only use Easydivx to generate the script (c:\easydivx\temp\easydivx.bat), then I stop the processing and edit the script.

I take out the audio processing since I find Graphedit superior to audiodec (and everything else I've tried). I then use lame after Graphedit, and use Nandub to mux the mp3 and the .avi. All I use Easydivx for is to generate the lst file of my vobs, execute vstrip, and give me the template for m2a which I change resize options, reference, and datarate I want.

Kinda kewl tho :) Hope this helps.

BTW, Palesi - I have always wanted to know what the iDCT setting actually does - is it only for decoding MPEG-2?

DJ Bobo
3rd April 2002, 10:12
Originally posted by auldarstarglade
I have always wanted to know what the iDCT setting actually does - is it only for decoding MPEG-2?

YES

palesi
3rd April 2002, 15:47
From the FlasKMPEG readme:



The video information inside MPEG files is stored in the frequency domain rather than in the spatial domain (the images we see). That way, the information gets compacted and that compactation can be used to compress (reduce) the amount of information you have to send over the transmission channel. MPEG uses the DCT (Discrete Cosine Transform) to translate spatial information into frequency information.
To bring back the spatial information from the MPEG stream you have to apply the iDCT, that is, the Inverse Discrete Cosine Transform, that undoes the DCT that was used during encoding.
Although MPEG is almost deterministic (given a MPEG stream the output should be identical in all decoders), the standard has a degree of freedom when choosing the iDCT to use. That way, the decoder can be more easily implemented depending on the hardware below it. What the standard requires from the decoder is that the iDCT meets IEEE-1180 specs, or in plain words, that the error from the iDCT doesn't go beyond what IEEE-1180 imposes.



That should give the point.

Amerzone
3rd April 2002, 19:44
Originally posted by auldarstarglade
If you visit:

http://easydivx.does.it

You can download the latest version of Easydivx which has support for Divx 5. I assume it also has a new version of divxauto.

Easydivx is a rather easy front-end that combines various utilities to make divx encoding easy. It uses vstrip, m2a to do the encoding, audiodec avimux etc etc.

Personally I only use Easydivx to generate the script (c:\easydivx\temp\easydivx.bat), then I stop the processing and edit the script.
Thanks for pointing out. In the news section they claim that the latest version supports DivX5, but they recommend DivX 4.12 to be used with this all-in-one tool. I checked their forum and in fact there are a lot of unsuccessful reports... Atm, I would prefer to stay on DivX4 and use the simple_frontend of chi that I'm talking about above.