Log in

View Full Version : min I-frame interval


R3g
27th June 2002, 08:24
Hi all !
I did a first pass of encoding last night, and I saw just this morning that I forgot to set the min I-frame interval, letting to the default of 1.
I tried to change it in the settings for the second pass, but I saw on vdub ouput that it didn't help : I got often 3 to 6 I-frame in a row.
so I believe I-frame places are written in the stat file, aren't they ?
Does I have to do another first pass, or is there another way to fix it ? I know just one pass isn't very much, but with my slow computer and all these filtering I'm doing, encoding is very slow (3 fps as average)
Thanks for your answers.

Teegedeck
27th June 2002, 11:33
Hi,

XviD decides to set an I-frame when it is smaller than a P-frame would be. The decision may not always be perfect but I think it's very close to it.

The min. interval of '1' means that XviD can decide by its internal threshholding when to set an I-frame, any setting > 1 forces it to use P-frames for the selected number of frames after the last I-frame. This is not a good idea, really...


You shouldn't change any settings from the 1st pass for the 2nd pass as this tends to lead to problems. So either do the first pass, again, or use the same interval that you used in the 1st pass for the 2nd pass. Not everything has to be perfect.

Greetings

R3g
27th June 2002, 13:57
Originally posted by Teegedeck
Hi,

XviD decides to set an I-frame when it is smaller than a P-frame would be. The decision may not always be perfect but I think it's very close to it.

Is that the only reason ? With interval set to 1, I can got up to 12 I-frames in a row. Isn't there any problem with that ? I remember the old times with m4c and DivX3, where too many keyframes gave really choppy playback.

Teegedeck
27th June 2002, 14:06
One reason could be that you use very high quantizers (caused by a too-small targeted filsize at too high a resolution), the inter/intra-threshhold isn't optimized for those and produces errors. Another may be the content you're encoding. It isn't anime by any chance?

And consecutive I-frames in DivX3.11 have never caused stuttering playback for me (on an old Celeron).

R3g
27th June 2002, 14:29
I'll watch for quantizer, but I'm encoding a 1h30 movie at 576*something, targeting 1 700mb cd with 112 kbps mp3 sound, so I don't think it is asking too much to the codec.

I redid the first pass with min interval set to 10, and a I can see in vdub for the 2nd pass, there are always more than 10 P-frames between 2 I-frames. Anymay, I'll do another 2nd pass with my previous settings to compare the quality at scene changes.

ookzDVD
28th June 2002, 04:25
@Teegedeck,


The min. interval of '1' means that XviD can decide by its internal threshholding when to set an I-frame, any setting > 1 forces it to use P-frames for the selected number of frames after the last I-frame. This is not a good idea, really...


Doom's guide mention that is not good idea to use 1 and at his
guide he is using 2 for both Min. I-frame and P-frame.

How could it be so confusing for me now ? :(

Wuntvor
28th June 2002, 07:34
ookzDVD:

Your mixing up quantizers with I-frames control.
Never use a qunatizer of 1 , its useless. But here we discuss spacing of I-frames, ie the minimum interval you can have between I-frames.

regards
/wuntvor

ookzDVD
28th June 2002, 08:55
@Wuntvor,

Thank you, it was my fault.

I notice that Doom's guide use 6 for that setting and
it still over 1 ;(