[MPlayer-dev-eng] aspect ratio with OSD
fenwick at freemail.hu
Sun Jan 23 17:33:57 CET 2005
2005-01-23, v keltezéssel 14.36-kor Csillag Kristof ezt írta:
> The problem is that we render the subtitles _before_ the scaling up at
> playback time, and we have no idea about what size (or more importantly)
> aspect will it be scaled to. Of course the information is available
> somewhere in mplayer's dataspace, but the vobsub rendering module is
> obviously not aware of it.
Basically, the problem is that aspect ratio is not passed to the OSD
level by the VO drivers; every function call exported from the
OSD level only takes two parameters, width and height, and because the
VO drivers can do rescaling (like Xv), we can not calculate the aspect
* * *
If we want to render OSD elements (both text subtitles and VOBsub
subtitles) with correct aspect rate, we must get the necessary
information from the VO drivers.
So, we have to opinions:
1. To modify every OSD call in every VO driver,
to include this one extra parameter besides
the width and the height. (~70 lines.)
2. To save this aspect rate (as displayed on the monitor) somewhere
when we set up the VO driver in vf_vo, and later use this value
from the OSD layer.
(2) would require much less work, but is ugly, because until now, all
information from vf_vo level to the OSD level was flowing via the actual
VO drivers (like X11, xv, etc.), so smugling this information directly
to the OSD layer (bypassing the VO drivers) would go agains the design
principles... but this would not stop it from working.
(And the codebase already looks like a haystack, anyway.:)
* * *
Someone with authority should tell me: which opinion should I take?
Csillag Kristof <fenwick at freemail.hu>
More information about the MPlayer-dev-eng