[MPlayer-dev-eng] [PATCH] changes in vf_get_image semantics
Jindrich Makovicka
makovick at kmlinux.fjfi.cvut.cz
Thu Nov 25 13:29:59 CET 2004
D Richard Felker III wrote:
> furthermore, ALL of this (image size, border, etc.) should be decided
> at CONFIG TIME, not everytime get_image is called. get_image should
> implicitly assume the same sizes config() was called with, otherwise
> it's nonsense. of course this would be a major pain to fix up in g1...
> let's discuss it more.
i hope this patch is already quite close. the dimensions are stored in
vf during mpcodecs_config_vo and vf_config_next. most of the calls of
get_image are changed to pass -1 as width and height, which means
"allocate the default dimensions". so now the args of get_image mean
really the allocated size, while mpi->w and mpi->h are always taken from
the corresponding vf. it made possible to remove some duplicate code
from vf's, which computes the dimensions, maybe even some vf->priv's
could be simplified as some fields just duplicate vf->w and vf->h, like
in vf_scale/crop/expand.
it can be still buggy, i haven't yet time to test it properly.
http://kmlinux.fjfi.cvut.cz/~makovick/getimage.diff
--
Jindrich Makovicka
More information about the MPlayer-dev-eng
mailing list