[MPlayer-dev-eng] [patch] subreader: SSA reading fix
Milan Čermák
mcermak at chello.cz
Sat Jun 17 14:03:09 CEST 2006
Hi all,
I got a bit tired about SSA parsing and decide to fix or rewrite it. As
I looked into the code found the parsing code kind of fuzzy. So at first
I tried to give it a bit more order.
To the problem: SSA parsing relied on number of commas in subtitle line.
The number varies from version to version so the original author decided
to use kind of heuristics. (I don't blame him/her for that. I understand
the reason.)
Fortunately, the precise number of commas can be obtained from "Format"
line. That's what my patch do.
Furthermore it fixes comma counting (the original can skip a comma if
there is an empty item) and in-line commands removing.
I'm planning to do more on subtitle parsing. As a preparation I made a
subreaderctx (context) structure, that will hold any reader specific
information.
Regards,
Milan "Manta" Cermak
-------------- next part --------------
A non-text attachment was scrubbed...
Name: subreaderctx.h
Type: text/x-chdr
Size: 452 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20060617/4bb65069/attachment.h>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: subreader.c.diff
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20060617/4bb65069/attachment.asc>
More information about the MPlayer-dev-eng
mailing list