[MPlayer-dev-eng] [PATCH] Remove warnings from libmpcodes/vf_geq.c
Diego Biurrun
diego at biurrun.de
Fri Oct 12 02:41:36 CEST 2007
On Thu, Oct 11, 2007 at 06:08:27PM +0800, Zuxy Meng wrote:
>
> As $subject. Now we have only 1 warnings instead of 7.
>
> --- libmpcodecs/vf_geq.c ?????? 24763??
> +++ libmpcodecs/vf_geq.c ????????????
> @@ -26,6 +26,7 @@
>
> #include "mp_msg.h"
> #include "cpudetect.h"
> +#include "mp_image.h"
>
> // Needed to bring in lrintf.
> #define HAVE_AV_CONFIG_H
> @@ -35,17 +36,7 @@
> #include "libavcodec/eval.h"
> #include "libavutil/common.h"
>
> -/* FIXME: common.h defines fprintf away when HAVE_AV_CONFIG
> - * is defined, but mp_image.h needs fprintf.
> - */
> -#undef fprintf
> -
> -#ifdef HAVE_MALLOC_H
> -#include <malloc.h>
> -#endif
> -
> #include "img_format.h"
> -#include "mp_image.h"
> #include "vf.h"
These are separate issues. The malloc.h #include is unnecessary, commit
the removal right away. Then you can reorder all of the #includes and
put everything before the FFmpeg #includes, that should take care of the
FIXME.
> @@ -61,23 +52,6 @@
>
> -static void get_image(struct vf_instance_s* vf, mp_image_t *mpi){
> - if(mpi->flags&MP_IMGFLAG_PRESERVE) return; // don't change
> - // ok, we can do pp in-place (or pp disabled):
> - vf->dmpi=vf_get_image(vf->next,mpi->imgfmt,
> - mpi->type, mpi->flags, mpi->w, mpi->h);
> - mpi->planes[0]=vf->dmpi->planes[0];
> - mpi->stride[0]=vf->dmpi->stride[0];
> - mpi->width=vf->dmpi->width;
> - if(mpi->flags&MP_IMGFLAG_PLANAR){
> - mpi->planes[1]=vf->dmpi->planes[1];
> - mpi->planes[2]=vf->dmpi->planes[2];
> - mpi->stride[1]=vf->dmpi->stride[1];
> - mpi->stride[2]=vf->dmpi->stride[2];
> - }
> - mpi->flags|=MP_IMGFLAG_DIRECT;
> -}
Probably OK, but should be a separate commit.
Diego
More information about the MPlayer-dev-eng
mailing list