[MPlayer-dev-eng] [PATCH] SUN XVR-100 VO driver 3. try

Diego Biurrun diego at biurrun.de
Wed Jul 25 17:28:30 CEST 2007


On Mon, Jul 23, 2007 at 08:27:22PM +0200, Balatoni Denes wrote:
> 
> Thanks for the review Diego, new pathc attached.

You are most welcome.

> --- mplayer.old/libvo/vo_xvr100.c	1970-01-01 01:00:00.000000000 +0100
> +++ mplayer/libvo/vo_xvr100.c	2007-07-23 15:49:38.011174000 +0200
> @@ -0,0 +1,478 @@
> +/* This actually doesn't change a thing, width greater than 1536 still won't work... */
> +#if 0
> +    /* if the source width was larger than what would fit in overlay scaler increase step_by values */
> +    i=pfb_srcwidth;
> +    while(i>/*pPriv->overlay_scaler_buffer_width*/1536){
> +        h_step++;
> +        h_inc >>=1;
> +        i=i/2;
> +    }
> +#endif

I don't like #if 0 blocks in code and some lines in this file are
terribly long.

> +#if 0 /* doesn't work for some reason */
> +    if (mpi->flags&MP_IMGFLAG_READABLE) return VO_FALSE;
> +    if (!(mpi->flags&MP_IMGFLAG_PLANAR)) return VO_FALSE; // FIXME: impossible for YV12, right?
> +    if (!(mpi->flags&MP_IMGFLAG_ACCEPT_STRIDE)) return VO_FALSE;
> +
> +    mpi->planes[0]=pfb_vbase + pfb_buffer1;
> +    if (mpi->flags&MP_IMGFLAG_SWAPPED){
> +        mpi->planes[1]=pfb_vbase + pfb_buffer3;
> +        mpi->planes[2]=pfb_vbase + pfb_buffer2;
> +    } else {
> +        mpi->planes[1]=pfb_vbase + pfb_buffer2;
> +        mpi->planes[2]=pfb_vbase + pfb_buffer3;
> +    }
> +    mpi->stride[0]=pfb_stride1;
> +    mpi->stride[1]=mpi->stride[2]=pfb_stride2;
> +    mpi->flags|=MP_IMGFLAG_DIRECT;
> +
> +    return VO_TRUE;
> +#endif

Same here, you could also put the return statements on their own line.

This needs a review from someone familiar with the vo system, Reimar?

As I said, the parts I maintain are OK.

Diego



More information about the MPlayer-dev-eng mailing list