[XviD-devel] Questions / Bug fixes / Patches

Michael Militzer michael at xvid.org
Thu Aug 19 23:49:35 CEST 2010


Hi,

I'm still not sure that there is a problem with MP4Box at all. When I look
at the console output that you posted using the "-nodrop" option things
appear to be fine actually: There's no message about variable framerate
and all input frames seem to have been imported (at least it's exactly 28
frames more imported than without "-nodrop"). It looks like MP4Box is
simply converting the N_VOPs to P_VOPs and this is indicated by the
"Removed 28 N-VOPs" message.

So: Are you sure that the resulting .mp4 file from the "MP4Box -nodrop"
command really is variable framerate and that not all input frames got
imported?

Regards,
Michael

PS: The max bitrates of the different levels constitute a max average
bitrate. There can be bitrate peaks that are considerably higher than
these bitrates and this is also perfectly legal as long as such peaks
do not underflow the vbv buffer.


Quoting Carl Eric Codere <cecodere at yahoo.ca>:

>> Hi Carl,
>
>>> F:\movies\outputs>..\tools\mp4box\MP4Box -fps 29.970 -nodrop -packed
>>>  -new -add .\sherlock_intro_qvga_Xvid_L6.m4v
>
>> why are you using "-packed" with MP4Box? Are you sure your input file is
>> a packed bitstream? I suppose the "-packed" option might be the reason
>> why the N_VOPs get stripped and the stream is converted to variable
>> framerate. Could you try without "-packed"?
>
>>> Information on the assertion error (I was encoding from virtualdub >1.9.9):
>>> mbcoding.c : line 595:
>>> estimated_length == coded_length
>
>> This assert is nothing to worry about. In fact, it got already removed
>> in the latest dev version of xvid.
>
>> Best regards,
>> Michael
>>
>
> Greetings,
>         Sorry, the mp4box parameters I sent you yesterday were
> added because I was debugging to try to resolve the problem,
> here is other trials I did when I encoded with an unpatched version
> of Xvid, the resulting file did have the N-VOP frames. As you can see
> I use mencoder to extract the raw MP4 stream, I then try to create a  
>  MP4 usingvmp4box.
>
>
> F:\movies\outputs>..\tools\MPlayer-rtm-svn-31878\mencoder.exe   
> sherlock_intro_qvg
> a_Xvid.avi -o .\sherlock_intro_qvga_Xvid.m4v -of rawvideo -nosound -ovc copy
> MEncoder Sherpya-SVN-r31878-4.2.5 (C) 2000-2010 MPlayer Team
> 159 audio & 347 video codecs
> success: format: 0  data: 0x0 - 0x269822
> AVI file format detected.
> [aviheader] Video stream found, -vid 0
> [aviheader] Audio stream found, -aid 1
> VIDEO:  [XVID]  320x240  24bpp  29.970 fps  289.9 kbps (35.4 kbyte/s)
> [V] filefmt:3  fourcc:0x44495658  size:320x240  fps:29.970  ftime:=0.0334
> videocodec: framecopy (320x240 24bpp fourcc=44495658)
> Pos:  40.8s   1224f (99%)  0.00fps Trem:   0min   1mb  A-V:0.000 [289:0]
>
> Video stream:  289.915 kbit/s  (36239 B/s)  size: 1480046 bytes    
> 40.841 secs  12
> 24 frames
>
> F:\movies\outputs>..\tools\mp4box\MP4Box -fps 29.970 -new -add   
> .\sherlock_intro_
> qvga_Xvid.m4v .\sherlock_intro_qvga_Xvid_256_Xvid.mp4
> MPEG-4 Video import - 320 x 240 @ 29.9700 FPS
> Indicated Profile: Simple Profile @ Level 3
> Import results: 1196 VOPs (6 Is - 1190 Ps)
> import using Variable Frame Rate - Removed 28 N-VOPs
> Converting to ISMA Audio-Video MP4 file...
> Saving .\sherlock_intro_qvga_Xvid_256_Xvid.mp4: 0.500 secs Interleaving
>
>
>
> F:\movies\outputs>..\tools\MPlayer-rtm-svn-31878\mencoder.exe   
> sherlock_intro_qvg
> a_Xvid.avi -o .\sherlock_intro_qvga_Xvid.m4v -of rawvideo -nosound -ovc copy
> MEncoder Sherpya-SVN-r31878-4.2.5 (C) 2000-2010 MPlayer Team
> 159 audio & 347 video codecs
> success: format: 0  data: 0x0 - 0x269822
> AVI file format detected.
> [aviheader] Video stream found, -vid 0
> [aviheader] Audio stream found, -aid 1
> VIDEO:  [XVID]  320x240  24bpp  29.970 fps  289.9 kbps (35.4 kbyte/s)
> [V] filefmt:3  fourcc:0x44495658  size:320x240  fps:29.970  ftime:=0.0334
> videocodec: framecopy (320x240 24bpp fourcc=44495658)
> Pos:  40.8s   1224f (99%)  0.00fps Trem:   0min   1mb  A-V:0.000 [289:0]
>
> Video stream:  289.915 kbit/s  (36239 B/s)  size: 1480046 bytes    
> 40.841 secs  12
> 24 frames
>
> F:\movies\outputs>..\tools\mp4box\MP4Box -fps 29.970 -new -nodrop   
> -add .\sherloc
> k_intro_qvga_Xvid.m4v .\sherlock_intro_qvga_Xvid_256_Xvid.mp4
> MPEG-4 Video import - 320 x 240 @ 29.9700 FPS
> Indicated Profile: Simple Profile @ Level 3
> Import results: 1224 VOPs (6 Is - 1218 Ps)
> Removed 28 N-VOPs
> Converting to ISMA Audio-Video MP4 file...
> Saving .\sherlock_intro_qvga_Xvid_256_Xvid.mp4: 0.500 secs Interleaving
>
>
> p.s: Furthermore, I am really sorry if it is not an appropriate
> to ask here, but Ihave a question regarding max. bitrate of
> MPEG-4 Part/2 for different profiles and levels. I have noticed,
> that for example if I configure the vfw codec to SP at L3 and I set the
> bitrate to 384 kbps (the max.) in 2-pass mode, this indicates the   
> overall bitrate of the stream, am I correct? After importing to   
> mp4box (with my patched version of xvid),the MP4 stream indicates a   
> max. bitrate that can go above the allowed Max. bitrate of 384 kbps   
> for that level, is that correct? Is this still respecting the   
> standard? From what I seem to understand by reading, and correct me   
> if I am wrong, the max. bitrate parameter of the standard is an   
> overall bitrate, and not the instant bitrate for a VOL? I am telling  
>  you this because I checked the code a bit and found a function   
> check_curve_for_vbv_compliancy() in plugin_2pass2.c that returns   
> VBV_PEAKRATE if the vbv_peakrate is above 0, which is not the case   
> for ISO profiles (as seen in config.c of the vfw driver).
>
> I have been trying to understand the max. bitrates for quite a while  
>  now, and am trying to  encode my videos to adhere strictly to the   
> ISO standards...
>
> Best regards,
> Carl
> _______________________________________________
> Xvid-devel mailing list
> Xvid-devel at xvid.org
> http://list.xvid.org/mailman/listinfo/xvid-devel
>
>





More information about the Xvid-devel mailing list