[MPlayer-dev-eng] Re: [MPlayer-users] ssa reader for mplayer using vf_overlay

Robert Ramiega jedi at plukwa.net
Thu Sep 29 12:02:16 CEST 2005


On Thu, Sep 29, 2005 at 01:37:30AM -0400, Robert Henney wrote:
> > 3) Rewrite the subreader from scratch, so that it handles
> > complex subtitles like SSA and the like correctly and uses
> > the new color draw functions.
> 
> I would certainly like to work on #3.  I'm not sure I can fathom
> tackling #1 or #2 until I become integrally familiar with those sections
> of mplayer.  As they are prerequisites to #3 though, I will see about
> spending some quality time looking the relative source over this
> weekend.
 Last week (around Sept, 21) Salvatore Falco posted his patch that makes
mplayer use Style definitions and positioning of SSA subs. This should also
work with JacoSUB and someother (i don't have samples of those subs so can't
verify but Salvatore said they work). I've managed to sync that patch with
latest cvs (relatively easy) and added my patch that allows to display italic 
(remember that font.desc version 2 thingy? -- this part was a bit tricky for
me).
 As of now this whole code is a bit messy and inconsistent but does work.
 The mess comes mostly from me =o( Salvatore made his code on the basis that
each vo_sub has only one style. This is true for subtitle format that
have concept of styles (like SSA has). In simple subtitle formats (like
mpl2, vplayer or microdvd) each vo_sub->text[] can have different style
-- from my experience it's just italic vs roman font).
 I got it all working yesterday late at night. Now i would like to get my
changes to work also with freetype and fontconfig. I was thinking on
somewhat unified access to both font.desc and freetype fonts which
could result in a layer that would shield internals from knowing which font
format is actually used (to some extent of course). This and proper
implementation (covering all subtitle formats) of vo_sub->text_style 
(introduced by Salavatore) could probably be easy to change to support
colorred fonts (info about color "style" needs to be stored along sub text)
 Bad side is that my knowledge of mplayer internals is sooo low, my
programming skills are rusty at most and my spare time is very limited (two
kids, wife and job can fill well over 24h/day). I'll keep on cleaning what i have
now. Maybe it will be usefull to anyone at some point. If not oh well this
is just another way of training my brain and get some geek-fun =o)))

-- 
Just a friendly Jedi Knight     | I find your lack of faith
Robert Ramiega jedi at plukwa.net  | disturbing




More information about the MPlayer-dev-eng mailing list