[MEncoder-users] Segmentation fault when embedding subtitles and rotating

Yørn de Jong mencoder at yorn.niroj.com
Mon May 5 02:06:15 CEST 2008


Dear developers

I have a linux box with an E2160 @ 1.80GHz processor.
I Fedora 8 and the mencoder delivered by livna.
I'm trying to convert a .mkv file with embedded subtitles to an  
rotated avi file
(my portable player likes it that way)
Therefor I wrote a shellscript (with some copy/pasting), which  
contains the following command:

                mencoder "${file}" -idx -noodml -ofps 20 \
                         -font /usr/share/fonts/liberation/ 
LiberationSans-Bold.ttf -slang und -mc 0 \
                         -vf scale=320:-2,expand=: 
240:::1,crop=320:240,rotate=1 \
                         -ovc lavc -ffourcc XVID -lavcopts \
                         vcodec=mpeg4:vbitrate=$ 
{VBITRATE}:vmax_b_frames=0:vhq \
                         -sws 9 -srate 44100 -oac mp3lame -lameopts \
                         cbr:br=128:mode=0 -ss ${ENC_START} -endpos 0:$ 
{LENGTH}:00 \
                         -o "${TARGET}${PARTEXT}.avi"

As you can see I have hardcoded the subtitle part for now,
it's "-font /usr/share/fonts/liberation/LiberationSans-Bold.ttf -slang  
und -mc 0"
("und" is the name of the language)
This causes a segfault. When I remove the rotate part, it works fine.
Without the subtitle line and with the rotate, it works fine as well.

The error i'm getting when I try to run this as given here is:

Pos:   5.3s    126f ( 0%) 108.81fps Trem:   0min   0mb  A-V:0.000  
[64:128]
Skipping frame!
Pos:   5.5s    132f ( 0%) 107.84fps Trem:   0min   0mb  A-V:0.000  
[105:127]
Skipping frame!
[mpeg4 @ 0x86c0450]slice end not reached but screenspace end (3 left  
7EF5C5, score= -123)
[mpeg4 @ 0x86c0450]concealing 1590 DC, 1590 AC, 1590 MV errors
[mpeg4 @ 0x86c0450]slice end not reached but screenspace end (6360  
left 56C33A, score= -123)
[mpeg4 @ 0x86c0450]concealing 1590 DC, 1590 AC, 1590 MV errors
Pos:   5.8s    138f ( 0%) 106.65fps Trem:   0min   0mb  A-V:0.000  
[114:127]
Skipping frame!
[mpeg4 @ 0x86c0450]slice end not reached but screenspace end (7189  
left 4D27A3, score= -130)
[mpeg4 @ 0x86c0450]concealing 1590 DC, 1590 AC, 1590 MV errors
[mpeg4 @ 0x86c0450]slice end not reached but screenspace end (5735  
left 4E9BD2, score= -130)
[mpeg4 @ 0x86c0450]concealing 1590 DC, 1590 AC, 1590 MV errors
Pos:   6.0s    144f ( 0%) 105.34fps Trem:   0min   0mb  A-V:0.000  
[119:127]
Skipping frame!
Pos:   6.3s    150f ( 0%) 104.75fps Trem:   0min   0mb  A-V:0.000  
[127:127]
Skipping frame!
[mpeg4 @ 0x86c0450]slice end not reached but screenspace end (3 left  
75CEA5, score= -138)
[mpeg4 @ 0x86c0450]concealing 1590 DC, 1590 AC, 1590 MV errors
[mpeg4 @ 0x86c0450]slice end not reached but screenspace end (6114  
left D3D3AF, score= -138)
[mpeg4 @ 0x86c0450]concealing 1590 DC, 1590 AC, 1590 MV errors
/usr/bin/meizu_prepare: line 242: 28208 Segmentation fault       
mencoder "${file}" -idx -noodml -ofps 20 -font /usr/share/fonts/ 
liberation/LiberationSans-Bold.ttf -slang und -mc 0 -vf  
scale=320:-2,expand=:240:::1,crop=320:240,rotate=1 -ovc lavc -ffourcc  
XVID -lavcopts vcodec=mpeg4:vbitrate=${VBITRATE}:vmax_b_frames=0:vhq - 
sws 9 -srate 44100 -oac mp3lame -lameopts cbr:br=128:mode=0 -ss $ 
{ENC_START} -endpos 0:${LENGTH}:00 -o "${TARGET}${PARTEXT}.avi"

The resulting file does contain the first few seconds of the film,
with the first two subtitles appearing.
The subtitles are placed where i'd expect them; at the left side.
However, the moment the first subtitle appears, some green vertical  
lines appear,
and with the 2nd subtitle the whole movie is green. Then the file ends.

I've tried a lot of combinations, one of them using another font,  
nothing appears to work.
Because this case crashes when using two features at the same time  
(embedding subtitles and rotating a movie)
which work fine when used seperately, I think this might be a bug in  
mencoder.
Can someone else please give some feedback on this? I really have no  
idea how to fix this.

Thanks!

Yørn de Jong


More information about the MEncoder-users mailing list