[Mplayer-cvslog] CVS: main/libmpcodecs vf.c,1.50,1.51

Arpi of Ize arpi at mplayerhq.hu
Thu Oct 10 03:09:34 CEST 2002


Update of /cvsroot/mplayer/main/libmpcodecs
In directory mail:/var/tmp.root/cvs-serv23120

Modified Files:
	vf.c 
Log Message:
don't honor stride hints if the next filter(chain) doesn't support stride


Index: vf.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/vf.c,v
retrieving revision 1.50
retrieving revision 1.51
diff -u -r1.50 -r1.51
--- vf.c	27 Sep 2002 21:08:36 -0000	1.50
+++ vf.c	10 Oct 2002 01:09:23 -0000	1.51
@@ -187,8 +187,17 @@
 	      int align=(mpi->flags&MP_IMGFLAG_PLANAR &&
 	                 mpi->flags&MP_IMGFLAG_YUV) ?
 			 (8<<mpi->chroma_x_shift)-1 : 15; // -- maybe FIXME
-	      mpi->width=w2=((w+align)&(~align));
-	      mpi->chroma_width=w2>>mpi->chroma_x_shift;
+	      w2=((w+align)&(~align));
+	      if(mpi->width!=w2){
+	          // we have to change width... check if we CAN co it:
+		  int flags=vf->query_format(vf,outfmt); // should not fail
+		  if(!(flags&3)) mp_msg(MSGT_DECVIDEO,MSGL_WARN,"??? vf_get_image{vf->query_format(outfmt)} failed!\n");
+//		  printf("query -> 0x%X    \n",flags);
+		  if(flags&VFCAP_ACCEPT_STRIDE){
+	              mpi->width=w2;
+		      mpi->chroma_width=w2>>mpi->chroma_x_shift;
+		  }
+	      }
 	  }
 	  
 	  // IF09 - allocate space for 4. plane delta info - unused




More information about the MPlayer-cvslog mailing list