Opened 19 years ago
Last modified 14 years ago
#346 new defect
mencoder ignores subtitle font settings when using ttf fonts
Reported by: | Owned by: | reimar | |
---|---|---|---|
Priority: | normal | Component: | core |
Version: | HEAD | Severity: | normal |
Keywords: | Cc: | nirmisgav@… | |
Blocked By: | Blocking: | ||
Reproduced by developer: | no | Analyzed by developer: | no |
Description
I try to encode some movies adding hardcoded subtitles. I found the optimal
font and font settings for me - when I set font parameters using mplayer
subtitles show exactly as I would like them to show. Unfortunately after using
the same exact options for mencoder I get the subtitles rendered with correct
font, but much smaller than what I need. Font I use is some TTF Arial variant
(but I tested it with differnt fonts with no luck).
It seems that this error/behaviour was introduced somewhere after 1.0pre6 -
I've been trying my luck with older versions and in 1.0pre6 everything works
fine (but older versions won't read my source files properly). I found this in
1.0pre7 first and today I tried the CVS version - it's still there.
Example command line (first pass only) is:
mencoder input.mkv -ovc lavc -lavcopts vcodec=mpeg4:vpass=1:vbitrate=1600 -oac
mp3lame -lameopts vbr=3:br=160 -o test.avi -ffourcc DIVX -frames 600
-font /usr/share/fonts/TrueType/arialbd.ttf -sid 0
Input file is some Matroska contained movie, but I tried it on normal avi's
with external subtitles - effect is the same.
Attachments (2)
Change History (11)
comment:1 by , 19 years ago
comment:2 by , 19 years ago
I _did_ tried (probably) every option related to subtitle font size. None of
them works with mencoder while exactly the same options (with empty config)
works fine with mplayer.
comment:3 by , 19 years ago
There are no font-related options in your example command, so please provide an
example that doesn't work and - preferably - some screenshots/frame captures.
comment:4 by , 19 years ago
by , 19 years ago
Attachment: | mencoder.jpg added |
---|
example of the video after encoding with mencoder (incorrectly)
comment:5 by , 19 years ago
comment:6 by , 19 years ago
Ok. So example that does not work:
First I removed mplayer config just to be sure that it does not introduce any
problems. Then I tried playing a video with subtitles using mplayer:
mplayer video.avi -sub subs.sub -subfont-text-scale 5 -subfont-blur 0
-font /usr/share/fonts/TrueType/arial.ttf
Everything is OK - mplayer shows big subtitles as it suuposed (scale 5).
Then I encoded piece of the same video with exactly the same parameters for
subtitles:
mencoder -ovc lavc -lavcopts vcodec=mpeg4:vbitrate=1600 -oac mp3lame -lameopts
vbr=3:br=160 -o xxx.avi -ffourcc DIVX -frames 100 video.avi -sub subs.sub
-subfont-text-scale 5 -subfont-blur 0
-font /usr/share/fonts/TrueType/arial.ttf
After playing then resulting xxx.avi the hardcoded subtitle looks like
mencoder just ignores -subfont-text-scale option.
Attached are the example screenshots.
comment:7 by , 17 years ago
Cc: | added |
---|
I have the same problem.
This is the command I use :
mencoder 1408.avi -ovc lavc -lavcopts vcodec=mpeg4:vbitrate=1000:vhq:keyint=250:threads=2 -oac mp3lame -lameopts cbr:br=128 -ffourcc XVID -vf scale=-2:180,crop=320:240,expand=320:240 -af resample=44100:0:0 -o 1409.avi -sub 1408.srt -flip-hebrew -fribidi-charset ISO8859-8 -slang he -font /usr/share/fonts/truetype/msttcorefonts/arial.ttf -subfont-encoding ISO8859-8 -subfont-text-scale 4 -nooverlapsub
If I run mplayer with the same font related flags they work fine (I see correctly), But when I use them with mencoder they just do nothing, so I get the subs as Gibrish instead of Hebrew. mencoder just ignore them.
I'm using Ubuntu Gutsy, mencoder version is: 2:1.0~rc1-0ubuntu11
Thanks,
Nir.
comment:9 by , 14 years ago
Owner: | changed from | to
---|
Try the
-subfont-autoscale
-subfont-text-scale
options.
Maybe it works with mplayer you already have them in the config?