View Full Version : MV Range
shon3i
15th January 2006, 15:28
How to control MV range in XviD. What the default MV range in XviD and what in DivX.
sysKin
15th January 2006, 16:53
What do you mean by MV range and why would you want to have any control over it?
shon3i
16th January 2006, 01:52
I see that option in x264, nerodigital asp&avc, and older xvid & divx codecs. Someone tell me that option improve quality. In x264 default value is 16,and i think sharktooth says that recommended value is 32. In nero that option can be something about 512 or 1024 for asp.
Didée
16th January 2006, 02:36
I see that option in x264, nerodigital asp&avc, and older xvid & divx codecs. Someone tell me that option improve quality.
Yes, but for XviD it's only true with waxing moon. With waning moon it would actually decrease XviD's quality. And with new moon, you could encode only in B/W.
Read: perhaps this option is not needed in XviD, or things internally are handled in another way. :)
(Hint: Vastly Handsome Qualigosaur.)
sysKin
16th January 2006, 03:13
I see that option in x264, nerodigital asp&avc, and older xvid & divx codecs. Someone tell me that option improve quality. In x264 default value is 16,and i think sharktooth says that recommended value is 32. In nero that option can be something about 512 or 1024 for asp.
Okay. XviD does not artificially limit motion range at all, and will always use the maximum range that is possible to write to the bitstream.
ASP uses a bitstream signal "fcode" to set the possible motion range. XviD manages this signal internally, matching it to the required motion range for any frame. You don't have control over it, other than patching the code to work differently.
Teegedeck
16th January 2006, 08:20
Yes, but for XviD it's only true with waxing moon. With waning moon it would actually decrease XviD's quality. And with new moon, you could encode only in B/W.
Read: perhaps this option is not needed in XviD, or things internally are handled in another way. :)
(Hint: Vastly Handsome Qualigosaur.);)
Yes, you are absolutely right there, Didée! As the Professional XviD User's Manual teaches us:
"In ye night of a full moon, the very handsome qualigosaurs will gather and join their hands and dance around the bonfire, calling upon the sysKin to vastly hype [old English for 'improve'] the quality and stretch their motion vectors to near the borders of infinity."
Didée
16th January 2006, 09:35
Eeeek! I mixed up the "very handsome qualigosaur" with the "vastly hyped quality" option. Back to primary school... :o
shon3i
16th January 2006, 13:16
Okay. XviD does not artificially limit motion range at all, and will always use the maximum range that is possible to write to the bitstream.
ASP uses a bitstream signal "fcode" to set the possible motion range. XviD manages this signal internally, matching it to the required motion range for any frame. You don't have control over it, other than patching the code to work differently.
Very interesting. I also hear that DivX in Insane Mode have bigger range realated than XviD, But i understand why DivX have bad picture quality realated than XviD
Teegedeck
16th January 2006, 13:35
A longer motion vector is not always the better motion vector (i.e. the one resulting in a small but high-quality frame in the very end). That also depends on the level of quantization (higher quantizer --> long motion vectors become less efficient). VHQ checks and double-checks what is the best decision for each MB & MV, that is what makes it such a great encoding tool.
BTW, Didée, we were both wrong! Very Handsome Qaligosaur (http://forum.doom9.org/showthread.php?p=259936&highlight=very+handsome+qaligosaur#post259936)!
sysKin
16th January 2006, 14:00
Very interesting. I also hear that DivX in Insane Mode have bigger range realated than XviD, But i understand why DivX have bad picture quality realated than XviD
How did you check that - I don't know ;)
But the higher Fcode, the more bits motion vectors take. If DivX sets fcode higher they have bigger range but overal use more bits.
The decision what fcode to use is kinda funny, but makes little differnece in practice.
This should definitely not depend on whether you have Insane mode or not. Motion vector range has nothing (or very little) to do with motion search precision.
shon3i
16th January 2006, 14:05
In xvid_encraw has switch 4mv and somethins switches me16 me8 and other how in wfv to see that switches is active
Teegedeck
16th January 2006, 14:13
I'm sorry, could you re-phrase that?
shon3i
16th January 2006, 14:37
I'm sorry, could you re-phrase that?
Sorry on very bad english. I see in the xvid_encraw beside vhq and motion precision, options like 4mv, me8, me16 something like macroblok partitons in x264
Teegedeck
16th January 2006, 15:56
Beats me. I seem to recall that at least the '4 motion vectors per MB' thing came only active with higher me search precision levels. But I'm really, really not sure.
Good question. VfW has spoilt me.
shon3i
16th January 2006, 16:12
I aslo see diamond search option and i think in xvid_ecraw can be preformed a multi pass encoding.
Teegedeck
16th January 2006, 19:15
The search patterns are directly connected to motion search precision once again. Don' worry about the names - the higher me precision, the better (and slower) is the motion search pattern used.
You really don't n e e d to set these parameters manually, you know. XviD is complicated and configurable enough as it is.
shon3i
17th January 2006, 14:25
XviD is not much complicated. I get better result with xvid_encraw. With xvid_encraw i get avg quantizer 2.60 and with vfw for same film get 3.50. I dont know how but i use all switches like me8 and me16. I aslo use only inter matrix without intra.
Teegedeck
17th January 2006, 15:19
1) Average quant doesn't say much about the quality
2) Especially not if you mess around like that. Do you use only inter matrix or only inter frames? That is quite a difference, but both are certainly bad ideas!
Using all switches without having an idea what they do and how they should be combined is just the wrong thing to do.
shon3i
17th January 2006, 15:38
I know that is Jawor 1CD matrix better than H263 anyway. Using MPEG Intra matrix and Jawor CD1 Inter give better quality at <600 bitrates. Movie looks more sharper and less blockness especialy in high motion scens
Teegedeck
17th January 2006, 18:40
shon3i, since you've started posting on this subforum you've been spurting things like 'this is best, that is best, I know better than you etc.' without showing any real expertise. On top of that you've repeatedly broken forum rules or been on the verge of it. My patience is about up now. You've already earned one strike for violating rule 12), be careful from now on OK?
Sagittaire
17th January 2006, 19:58
In xvid_encraw has switch 4mv and somethins switches me16 me8 and other how in wfv to see that switches is active
1) These options are automaticaly actived with ME profil and VHQ profil
static const int motion_presets[] = {
/* quality 0 */
0,
/* quality 1 */
XVID_ME_ADVANCEDDIAMOND16,
/* quality 2 */
XVID_ME_ADVANCEDDIAMOND16 | XVID_ME_HALFPELREFINE16,
/* quality 3 */
XVID_ME_ADVANCEDDIAMOND16 | XVID_ME_HALFPELREFINE16 |
XVID_ME_ADVANCEDDIAMOND8 | XVID_ME_HALFPELREFINE8,
/* quality 4 */
XVID_ME_ADVANCEDDIAMOND16 | XVID_ME_HALFPELREFINE16 |
XVID_ME_ADVANCEDDIAMOND8 | XVID_ME_HALFPELREFINE8 |
XVID_ME_CHROMA_PVOP | XVID_ME_CHROMA_BVOP,
/* quality 5 */
XVID_ME_ADVANCEDDIAMOND16 | XVID_ME_HALFPELREFINE16 |
XVID_ME_ADVANCEDDIAMOND8 | XVID_ME_HALFPELREFINE8 |
XVID_ME_CHROMA_PVOP | XVID_ME_CHROMA_BVOP,
/* quality 6 */
XVID_ME_ADVANCEDDIAMOND16 | XVID_ME_HALFPELREFINE16 | XVID_ME_EXTSEARCH16 |
XVID_ME_ADVANCEDDIAMOND8 | XVID_ME_HALFPELREFINE8 | XVID_ME_EXTSEARCH8 |
XVID_ME_CHROMA_PVOP | XVID_ME_CHROMA_BVOP,
};
#define ME_ELEMENTS (sizeof(motion_presets)/sizeof(motion_presets[0]))
static const int vop_presets[] = {
/* quality 0 */
0,
/* quality 1 */
0,
/* quality 2 */
XVID_VOP_HALFPEL,
/* quality 3 */
XVID_VOP_HALFPEL | XVID_VOP_INTER4V,
/* quality 4 */
XVID_VOP_HALFPEL | XVID_VOP_INTER4V,
/* quality 5 */
XVID_VOP_HALFPEL | XVID_VOP_INTER4V |
XVID_VOP_TRELLISQUANT,
/* quality 6 */
XVID_VOP_HALFPEL | XVID_VOP_INTER4V |
XVID_VOP_TRELLISQUANT | XVID_VOP_HQACPRED,
};
#define VOP_ELEMENTS (sizeof(vop_presets)/sizeof(vop_presets[0]))
static const int rd_me_presets[] = {
/* quality 0 */
0,
/* quality 1 */
0,
/* quality 2 */
XVID_ME_HALFPELREFINE16_RD | XVID_ME_QUARTERPELREFINE16_RD,
/* quality 3 */
XVID_ME_HALFPELREFINE16_RD | XVID_ME_QUARTERPELREFINE16_RD |
XVID_ME_HALFPELREFINE8_RD | XVID_ME_QUARTERPELREFINE8_RD |
XVID_ME_CHECKPREDICTION_RD,
/* quality 4 */
XVID_ME_HALFPELREFINE16_RD | XVID_ME_QUARTERPELREFINE16_RD |
XVID_ME_HALFPELREFINE8_RD | XVID_ME_QUARTERPELREFINE8_RD |
XVID_ME_CHECKPREDICTION_RD | XVID_ME_EXTSEARCH_RD,
2) xvid_encraw don't produce better quality than XviD vfw. IMO xvid_encraw is a very good log only because it's CLI with VES *.m4v in output.
Teegedeck
17th January 2006, 20:01
:goodpost:
Thanks.
shon3i
17th January 2006, 20:34
Thanks for help Sagittaire. Teegedeck i am not asking what is the best. I only search what is best for me and my encodings. I don't understand. btw anyway i switched to x264 and i try after 3 yeras with xvid encoding to compare this two codecs. I don't have a much time to expreminet. I get better result with xvid_encraw i dont know why.
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.