[MPlayer-dev-eng] display of subtitles

Arpi arpi at thot.banki.hu
Fri Jan 3 22:40:04 CET 2003


Hi,

> >From looking at the source I figured that mplayer reads (external)
> subtitle files completely at the beginning and further assumes that
> they have been read completely.
> 
> For OGM files that can not be achieved. Therefore subtitles that are
> contained in an OGM are displayed whenever the demuxer READs them -
> which is not necessarily when they SHOULD be displayed (as given by
> their granulepos), although it is for all 'correctly' interleaved OGM
> files.
> 
> My question: is the assumption above correct? What would be required to
yes...

> change that behaviour - and what would that behaviour be then? The
> ability to read subtitle packets from a demuxer and queue/display them
> appropriately?

probably subtitle queueing in demuxer layer.
i've been thinking about it just today, when saw again the spu queue patch.

we should handle subtitles just like audio & video packets, via teh queueing
functions of libmpdemux. currently the raw spu packets are queued there.

maybe we should move the spu re-assembly to the demuxer layer, where it
belongs to. so demuxer could queue assembled ready-to-view packets insteda
of the raw unprocessed ones.

also, this queue could handle other kind of subtitles, i mean ascii ones.
it could solve several hacks, like the closed-captions or ogm subtitles.
anyway it's a big change, and we should delay it to after 0.90 release if
ever done. (i can see many problems appearing as soon as we start it).

back to your question.
is tehre any ogm files where the current way fails?
are the subs read too early or too late?
if teh former, then a queue could help. if they arrive too late, it's a big
issue, it may mean that the ogm demuxer should read more than needed.


A'rpi / Astral & ESP-team

--
Developer of MPlayer, the Movie Player for Linux - http://www.MPlayerHQ.hu


More information about the MPlayer-dev-eng mailing list