[MPlayer-dev-eng] [PATCH] get rid of lots of useless/duplicate code in vo_xv/vo_xvmc

Ivan Kalvachev ikalvachev at gmail.com
Tue Mar 6 15:55:06 CET 2007


2007/3/6, Ivan Kalvachev <ikalvachev at gmail.com>:
> 2007/3/6, Reimar Döffinger <Reimar.Doeffinger at stud.uni-karlsruhe.de>:
> > Hello,
> > On Tue, Mar 06, 2007 at 04:01:22PM +0200, Ivan Kalvachev wrote:
> > > 2007/3/6, Reimar Döffinger <Reimar.Doeffinger at stud.uni-karlsruhe.de>:
> > > >On Sun, Feb 18, 2007 at 11:32:04AM +0100, Reimar D?ffinger wrote:
> > > >> see attached patch.
> > > >> Could not see it breaking anything...
> > > >
> > > >Any comments?
> > >
> > > Haven't tested it, but it looks OK.
> > >
> > > I just don't like foo(void) functions that mess with "globals", but I
> > > guess putting all these variables in struct and passing it around is
> > > too much work for such trivial change ;)
> > >
> > > btw how about naming the function calc_drwXY() ?
> > > usually get_something() is expected to return the thing it gets ;)
> >
> > Well, I can at least pass around pointers to the global variable as in
> > attached patch, if you prefer that.
> > In the long term a vo struct would be nice, but that is a much bigger
> > change to do in a useful way and would be overkill for passing around to
> > such a simple function, too.
> > Btw. should I attempt moving the code shared between those two vos to
> > a xvideo.c (or similar)? At least most of config could be put there I
> > think (though not sure how ugly it would get with all those globals).
>
> Don't move it, I have a cropping patch that may need to mess these for
> xvmc case.
> I'll do some xvmc stuff after I finish with my current project.
>

Patch OK to commit.



More information about the MPlayer-dev-eng mailing list