[MPlayer-users] [BUGREPORT] libavcodec bframes bug

Anders Rune Jensen anders at gnulinux.dk
Sat Jan 4 23:12:28 CET 2003


Arpi <arpi at thot.banki.hu> writes:

> [Automatic answer: RTFM (read DOCS, FAQ), also read DOCS/bugreports.html]
> Hi,
>
>> Just testing the new cool features of libavcodec when I encountered
>> this bug:
>
> fresh (today+) CVS or older cvs or rc2?

allways cvs of both mplayer and libavcodec! I'm a long time mplayer
user :)

>> When I enable b-frames mencoder crashes, I've tried without b-frames
>> and it works ok. I fails after about 30 seconds of encoding.
>> 
>> I get an error:
>> 
>> mencoder: ratecontrol.c:584: ff_rate_estimate_qscale: Assertion
>> `picture_number<rcc->num_entries' failed.
>
> looks like you used different options for 1st and 2nd passes.

It never reaches pass2, it fails after 6.1 (to be exact) seconds in
the first pass.

aha! the error mentioned was from the second pass, the first pass just
seg. faults. Let me see what I can get from a gdb.

0x08171111 in put_mpeg4_qpel16_h_lowpass (
    dst=0xbffe5bac "\025\025\025\023", '\022' <repeats 12 times>, "\025\025\025\023", '\022' <repeats 12 times>, "\025\025\025\023", '\022' <repeats 12 times>, "\025\025\025\023", '\022' <repeats 12 times>, "\025\025\025\023", '\022' <repeats 12 times>, "\025\025\025\023", '\022' <repeats 12 times>, "\025\025\025\023", '\022' <repeats 12 times>, "\025\025\025\023", '\022' <repeats 12 times>, "\025\025\025\023", '\022' <repeats 12 times>, "\025\025\025\023", '\022' <repeats 12 times>, "\025\025\025\023", '\022' <repeats 12 times>, "\025\025\025\023", '\022' <repeats 12 times>, "\025\025\025\023\022\022\022\022"..., 
    src=0x413be92b "\024\025\025\024", '\022' <repeats 26 times>, "\021\021\020\020\017\017", '\016' <repeats 35 times>, "\017\021\023\024\023\023\023\023\023\023\023\023\023\023\026\026\026\026\027\027\027\027\025\025\025\025\025\025\025\025", '\027' <repeats 24 times>, "\026\026\026\026\026\026\026\026", '\027' <repeats 16 times>, "\023\023\023\023\023\023\023\023\024\024\024\025\025", '\026' <repeats 11 times>, '\027' <repeats 16 times>, "\026\026\026\026\026\026\026\026\025\025\025"..., dstStride=16, srcStride=672, h=17) at dsputil.c:1157
#1  0x081748d2 in put_qpel16_mc22_c (
    dst=0x839abf0 ",(%!\035\032\031\030\027\027\026\026\026\025\023\023", 
    src=0x413be92b "\024\025\025\024", '\022' <repeats 26 times>, "\021\021\020\020\017\017", '\016' <repeats 35 times>, "\017\021\023\024\023\023\023\023\023\023\023\023\023\023\026\026\026\026\027\027\027\027\025\025\025\025\025\025\025\025", '\027' <repeats 24 times>, "\026\026\026\026\026\026\026\026", '\027' <repeats 16 times>, "\023\023\023\023\023\023\023\023\024\024\024\025\025", '\026' <r---Type <return> to continue, or q <return> to quit---
epeats 11 times>, '\027' <repeats 16 times>, "\026\026\026\026\026\026\026\026\025\025\025"..., stride=672) at dsputil.c:1157
#2  0x081a9afa in simple_direct_qpel_epzs_motion_search (s=0x83703e0, block=0, 
    mx_ptr=0xbffe6b24, my_ptr=0xbffe6b28, P=0xbffe6b2c, pred_x=0, pred_y=0, 
    xmin=-8, ymin=-8, xmax=7, ymax=7, ref_picture=0x8370e78, 
    last_mv=0x8399f70, ref_mv_scale=16384, mv_penalty=0x83b5712)
    at motion_est_template.c:855
#3  0x081b6cde in ff_estimate_b_frame_motion (s=0x83703e0, mb_x=36, mb_y=16)
    at motion_est.c:1342
#4  0x08150d5b in encode_picture (s=0x83703e0, picture_number=149)
    at mpegvideo.c:2822
#5  0x08143b7b in MPV_encode_picture (avctx=0x831f570, buf=0x40c11008 "", 
    buf_size=2097152, data=0x831f4e0) at mpegvideo.c:1227
#6  0x0814074c in avcodec_encode_video (avctx=0x831f570, buf=0x40c11008 "", 
    buf_size=2097152, pict=0x831f4e0) at utils.c:300
#7  0x0806d748 in put_image (vf=0x831f468, mpi=0x83478f8) at ve_lavc.c:473
#8  0x08080e91 in vf_next_put_image (vf=0x831f750, mpi=0x83478f8) at vf.c:399
#9  0x080820e6 in put_image (vf=0x831f750, mpi=0x8347890) at vf_expand.c:262
#10 0x08080e91 in vf_next_put_image (vf=0x831f7d0, mpi=0x8347890) at vf.c:399
#11 0x08082ca1 in put_image (vf=0x831f7d0, mpi=0x8347828) at vf_scale.c:217
#12 0x08080e91 in vf_next_put_image (vf=0x831f838, mpi=0x8347828) at vf.c:399
#13 0x08081645 in put_image (vf=0x831f838, mpi=0x83c37c0) at vf_crop.c:62
#14 0x08074b20 in decode_video (sh_video=0x83222d0, start=0x844c220 "", 
    in_size=39853, drop_frame=0) at dec_video.c:329
#15 0x0804e143 in main (argc=12, argv=0xbffffc84) at mencoder.c:1088
#16 0x409f93c1 in __libc_start_main () from /lib/libc.so.6

>> The input file I'm trying to encode is quite big because I just copied
>> the dvd into one single file, this may be the problem. ls -l
>> gladiator.vob: 5.699.664.772 bytes
>
> coudl you cut and upload a big enough part, along with a script containing
> the commands you executed (for all passes) for reproducing the bug?
>
> 30s in .vob is around 30MB.
>
> /dev/hdf1              77G   20G   57G  26% /home/ftp
>
> the mphq ftp space should be enough :)

will do

>> mencoder ../gladiator.vob -oac copy -ovc lavc -vop
>> scale=640:272,crop=720:420:0: 78 -lavcopts
>> vcodec=mpeg4:vhq:vbitrate=1075:keyint=300:qpel:cmp=3:subcmp=3:vmax_
>> b_frames=2:vpass=1 -o gladiator-rip.avi
>
> nice...

Réme's mail about the new options was very nice! Just doing my own
testing of the new things :))

>
> A'rpi / Astral & ESP-team

-- 
Anders Rune Jensen



More information about the MPlayer-users mailing list