[MPlayer-cvslog] CVS: main/libmpcodecs ad_libdv.c, 1.2, 1.3 vd_dmo.c, 1.3, 1.4 vd_dshow.c, 1.10, 1.11 vd_ffmpeg.c, 1.161, 1.162 vd_vfw.c, 1.29, 1.30 ve_lavc.c, 1.137, 1.138 ve_raw.c, 1.8, 1.9 ve_vfw.c, 1.23, 1.24 vf.c, 1.125, 1.126 vf_crop.c, 1.19, 1.20 vf_cropdetect.c, 1.14, 1.15 vf_expand.c, 1.35, 1.36 vf_fame.c, 1.13, 1.14 vf_format.c, 1.13, 1.14 vf_framestep.c, 1.3, 1.4 vf_noformat.c, 1.3, 1.4 vf_palette.c, 1.14, 1.15 vf_phase.c, 1.6, 1.7 vf_test.c, 1.9, 1.10 vf_tile.c, 1.4, 1.5 vf_yuy2.c, 1.10, 1.11 vf_yvu9.c, 1.8, 1.9

Reynaldo H. Verdejo CVS syncmail at mplayerhq.hu
Fri Mar 31 02:15:50 CEST 2006


CVS change done by Reynaldo H. Verdejo CVS

Update of /cvsroot/mplayer/main/libmpcodecs
In directory mail:/var2/tmp/cvs-serv7767/libmpcodecs

Modified Files:
	ad_libdv.c vd_dmo.c vd_dshow.c vd_ffmpeg.c vd_vfw.c ve_lavc.c 
	ve_raw.c ve_vfw.c vf.c vf_crop.c vf_cropdetect.c vf_expand.c 
	vf_fame.c vf_format.c vf_framestep.c vf_noformat.c 
	vf_palette.c vf_phase.c vf_test.c vf_tile.c vf_yuy2.c 
	vf_yvu9.c 
Log Message:
Part2 of several printf2mp_msg changes in patch from Otvos Attila oattila AT chello DOT hu with LOTS of modifications by me

Index: ad_libdv.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/ad_libdv.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- ad_libdv.c	30 Aug 2002 21:44:20 -0000	1.2
+++ ad_libdv.c	31 Mar 2006 00:15:47 -0000	1.3
@@ -6,6 +6,8 @@
 #include <math.h>
 
 #include "config.h"
+#include "mp_msg.h"
+#include "help_mp.h"
 
 #ifdef HAVE_LIBDV095
 
@@ -86,7 +88,7 @@
    dv_parse_header(decoder, dv_audio_frame);
    
    if(xx!=decoder->frame_size)
-       printf("warning! audio framesize differs! read=%d  hdr=%d  \n",
+       mp_msg(MSGT_GLOBAL,MSGL_WARN,MSGTR_MPCODECS_AudioFramesizeDiffers,
            xx, decoder->frame_size);
 
    if (dv_decode_full_audio(decoder, dv_audio_frame,(int16_t**) audioBuffers))

Index: vd_dmo.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/vd_dmo.c,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- vd_dmo.c	6 Jul 2004 11:14:28 -0000	1.3
+++ vd_dmo.c	31 Mar 2006 00:15:47 -0000	1.4
@@ -77,7 +77,7 @@
 	sh->disp_w, sh->disp_h);
     
     if(!mpi){	// temporary!
-	printf("couldn't allocate image for cinepak codec\n");
+	mp_msg(MSGT_DECVIDEO,MSGL_WARN,MSGTR_MPCODECS_CouldntAllocateImageForCinepakCodec);
 	return NULL;
     }
 

Index: vd_dshow.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/vd_dshow.c,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -r1.10 -r1.11
--- vd_dshow.c	4 May 2005 20:35:21 -0000	1.10
+++ vd_dshow.c	31 Mar 2006 00:15:47 -0000	1.11
@@ -106,7 +106,7 @@
 	sh->disp_w, sh->disp_h);
     
     if(!mpi){	// temporary!
-	printf("couldn't allocate image for cinepak codec\n");
+	mp_msg(MSGT_DECVIDEO,MSGL_WARN,MSGTR_MPCODECS_CouldntAllocateImageForCinepakCodec);
 	return NULL;
     }
 

Index: vd_ffmpeg.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/vd_ffmpeg.c,v
retrieving revision 1.161
retrieving revision 1.162
diff -u -r1.161 -r1.162
--- vd_ffmpeg.c	27 Mar 2006 10:32:52 -0000	1.161
+++ vd_ffmpeg.c	31 Mar 2006 00:15:47 -0000	1.162
@@ -248,7 +248,7 @@
 #else
     if(lavc_codec->id == CODEC_ID_MPEG2VIDEO_XVMC){
 #endif
-        printf("vd_ffmpeg: XVMC accelerated codec\n");
+        mp_msg(MSGT_DECVIDEO, MSGL_INFO, MSGTR_MPCODECS_XVMCAcceleratedCodec);
         assert(ctx->do_dr1);//these are must to!
         assert(ctx->do_slices); //it is (vo_)ffmpeg bug if this fails
         avctx->flags|= CODEC_FLAG_EMU_EDGE;//do i need that??!!
@@ -333,8 +333,8 @@
 	    uint8_t *p = avctx->extradata;
 	    
 	    for (x=0; x<avctx->extradata_size; x++)
-		printf("[%x] ", p[x]);
-	    printf("\n");
+		mp_msg(MSGT_DECVIDEO, MSGL_INFO,"[%x] ", p[x]);
+	    mp_msg(MSGT_DECVIDEO, MSGL_INFO,"\n");
 	}
 #endif
     }
@@ -433,9 +433,9 @@
     if(lavc_param_vstats){
         int i;
         for(i=1; i<32; i++){
-            printf("QP: %d, count: %d\n", i, ctx->qp_stat[i]);
+            mp_msg(MSGT_DECVIDEO, MSGL_INFO,"QP: %d, count: %d\n", i, ctx->qp_stat[i]);
         }
-        printf("Arithmetic mean of QP: %2.4f, Harmonic mean of QP: %2.4f\n", 
+        mp_msg(MSGT_DECVIDEO, MSGL_INFO,MSGTR_MPCODECS_ArithmeticMeanOfQP, 
             ctx->qp_sum / avctx->coded_frame->coded_picture_number,
             1.0/(ctx->inv_qp_sum / avctx->coded_frame->coded_picture_number)
             );
@@ -634,7 +634,7 @@
   if (!pic->buffer_hints) {
 #endif
     if(ctx->b_count>1 || ctx->ip_count>2){
-        printf("DR1 failure\n");
+        mp_msg(MSGT_DECVIDEO, MSGL_WARN, MSGTR_MPCODECS_DRIFailure);
 
         ctx->do_dr1=0; //FIXME
         avctx->get_buffer= avcodec_default_get_buffer;
@@ -921,7 +921,7 @@
     mpi=mpcodecs_get_image(sh, MP_IMGTYPE_EXPORT, MP_IMGFLAG_PRESERVE,
 	avctx->width, avctx->height);
     if(!mpi){	// temporary!
-	printf("couldn't allocate image for codec\n");
+	mp_msg(MSGT_DECVIDEO, MSGL_WARN, MSGTR_MPCODECS_CouldntAllocateImageForCodec);
 	return NULL;
     }
     
@@ -971,7 +971,7 @@
         avctx->get_buffer= mc_get_buffer;
         avctx->release_buffer= mc_release_buffer;
         avctx->draw_horiz_band = mc_render_slice;
-        printf("vd_ffmpeg: XVMC accelerated MPEG2\n");
+        mp_msg(MSGT_DECVIDEO, MSGL_INFO, MSGTR_MPCODECS_XVMCAcceleratedMPEG2);
         assert(ctx->do_dr1);//these are must to!
         assert(ctx->do_slices); //it is (vo_)ffmpeg bug if this fails
         avctx->flags|= CODEC_FLAG_EMU_EDGE;//do i need that??!!
@@ -979,7 +979,7 @@
     }
 #endif
     for(i=0;fmt[i]!=-1;i++){
-        printf("trying pixfmt=%d\n",i);
+        mp_msg(MSGT_DECVIDEO, MSGL_INFO, MSGTR_MPCODECS_TryingPixfmt,i);
         if( init_vo(sh,fmt[i]) >= 0)
 	    return fmt[i];
     }
@@ -997,7 +997,7 @@
     
 //  printf("vd_ffmpeg::mc_get_buffer (xvmc) %d %d %d\n", pic->reference, ctx->ip_count, ctx->b_count);
     if(!avctx->xvmc_acceleration){
-        printf("vd_ffmpeg::mc_get_buffer should work only with XVMC acceleration !!");
+        mp_msg(MSGT_DECVIDEO, MSGL_INFO, MSGTR_MPCODECS_McGetBufferShouldWorkOnlyWithXVMC);
         assert(0);
         exit(1);
 //        return -1;//!!fixme check error conditions
@@ -1005,10 +1005,10 @@
     assert(avctx->draw_horiz_band == mc_render_slice);
     assert(avctx->release_buffer == mc_release_buffer);
     if( mp_msg_test(MSGT_DECVIDEO,MSGL_DBG5) )
-        printf("vd_ffmpeg::mc_get_buffer\n");
+        mp_msg(MSGT_DECVIDEO, MSGL_DBG5, "vd_ffmpeg::mc_get_buffer\n");
 
     if(init_vo(sh,avctx->pix_fmt) < 0){
-        printf("vd_ffmpeg: Unexpected init_vo error\n");
+        mp_msg(MSGT_DECVIDEO, MSGL_WARN, MSGTR_MPCODECS_UnexpectedInitVoError);
         exit(1);
 //        return -1;//!!fixme check error conditions
     }
@@ -1025,14 +1025,14 @@
     mpi= mpcodecs_get_image(sh, MP_IMGTYPE_IPB,flags ,
                             avctx->width, avctx->height);
     if(mpi==NULL){
-        printf("Unrecoverable error, render buffers not taken\n");
+        mp_msg(MSGT_DECVIDEO, MSGL_ERR, MSGTR_MPCODECS_UnrecoverableErrorRenderBuffersNotTaken);
         assert(0);
         exit(1);
 //        return -1;//!!fixme check error conditions in ffmpeg
     };
     
     if( (mpi->flags & MP_IMGFLAG_DIRECT) == 0){
-        printf("Only buffers allocated by vo_xvmc allowed\n");
+        mp_msg(MSGT_DECVIDEO, MSGL_ERR, MSGTR_MPCODECS_OnlyBuffersAllocatedByVoXvmcAllowed);
         assert(0);
         exit(1);
 //        return -1;//!!fixme check error conditions in ffmpeg
@@ -1072,7 +1072,7 @@
 
     render=(xvmc_render_state_t*)mpi->priv;//same as data[2]
     if( mp_msg_test(MSGT_DECVIDEO,MSGL_DBG5) )
-        printf("vd_ffmpeg::mc_get_buffer (render=%p)\n",render);
+        mp_msg(MSGT_DECVIDEO, MSGL_DBG5, "vd_ffmpeg::mc_get_buffer (render=%p)\n",render);
     assert(render != 0);
     assert(render->magic == MP_XVMC_RENDER_MAGIC);
     render->state |= MP_XVMC_STATE_PREDICTION;
@@ -1099,7 +1099,7 @@
 //mark the surface as not requared for prediction
     render=(xvmc_render_state_t*)pic->data[2];//same as mpi->priv
     if( mp_msg_test(MSGT_DECVIDEO,MSGL_DBG5) )
-        printf("vd_ffmpeg::mc_release_buffer (render=%p)\n",render);
+        mp_msg(MSGT_DECVIDEO, MSGL_DBG5, "vd_ffmpeg::mc_release_buffer (render=%p)\n",render);
     assert(render!=NULL);
     assert(render->magic==MP_XVMC_RENDER_MAGIC);
     render->state&=~MP_XVMC_STATE_PREDICTION;

Index: vd_vfw.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/vd_vfw.c,v
retrieving revision 1.29
retrieving revision 1.30
diff -u -r1.29 -r1.30
--- vd_vfw.c	27 Mar 2006 17:25:41 -0000	1.29
+++ vd_vfw.c	31 Mar 2006 00:15:47 -0000	1.30
@@ -303,7 +303,7 @@
 	MP_IMGTYPE_STATIC : MP_IMGTYPE_TEMP, MP_IMGFLAG_ACCEPT_WIDTH, 
 	sh->disp_w, sh->disp_h);
     if(!mpi){	// temporary!
-	printf("couldn't allocate image for cinepak codec\n");
+	mp_msg(MSGT_DECVIDEO,MSGL_WARN,MSGTR_MPCODECS_CouldntAllocateImageForCinepakCodec);
 	return NULL;
     }
 

Index: ve_lavc.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/ve_lavc.c,v
retrieving revision 1.137
retrieving revision 1.138
diff -u -r1.137 -r1.138
--- ve_lavc.c	21 Mar 2006 23:06:09 -0000	1.137
+++ ve_lavc.c	31 Mar 2006 00:15:47 -0000	1.138
@@ -590,7 +590,7 @@
     lavc_venc_context->flags = 0;
     if (lavc_param_mb_decision)
     {
-	printf("High quality encoding selected (non real time)!\n");
+	mp_msg(MSGT_MENCODER, MSGL_INFO, MSGTR_MPCODECS_HighQualityEncodingSelected);
 #if LIBAVCODEC_BUILD < 4673
         lavc_venc_context->flags = CODEC_FLAG_HQ;
 #else
@@ -740,7 +740,7 @@
     /* fixed qscale :p */
     if (lavc_param_vqscale)
     {
-	printf("Using constant qscale = %f (VBR)\n", lavc_param_vqscale);
+	mp_msg(MSGT_MENCODER, MSGL_INFO, MSGTR_MPCODECS_UsingConstantQscale, lavc_param_vqscale);
 	lavc_venc_context->flags |= CODEC_FLAG_QSCALE;
 #if LIBAVCODEC_BUILD >= 4668
         lavc_venc_context->global_quality= 
@@ -968,7 +968,7 @@
         double f= lavc_venc_context->width*lavc_venc_context->height*255.0*255.0;
         f*= lavc_venc_context->coded_frame->coded_picture_number;
         
-        printf("PSNR: Y:%2.2f, Cb:%2.2f, Cr:%2.2f, All:%2.2f\n",
+        mp_msg(MSGT_MENCODER, MSGL_INFO, "PSNR: Y:%2.2f, Cb:%2.2f, Cr:%2.2f, All:%2.2f\n",
             psnr(lavc_venc_context->error[0]/f),
             psnr(lavc_venc_context->error[1]*4/f),
             psnr(lavc_venc_context->error[2]*4/f),

Index: ve_raw.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/ve_raw.c,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -r1.8 -r1.9
--- ve_raw.c	21 Mar 2006 21:26:40 -0000	1.8
+++ ve_raw.c	31 Mar 2006 00:15:47 -0000	1.9
@@ -4,6 +4,7 @@
 
 #include "config.h"
 #include "mp_msg.h"
+#include "help_mp.h"
 
 #include "codec-cfg.h"
 #include "stream.h"
@@ -68,7 +69,7 @@
 	mux_v->bih->biBitCount = 16;
 	break;
     default:
-	printf("ve_raw: raw output with fourcc [%x] not supported!\n", fmt);
+	mp_msg(MSGT_MENCODER, MSGL_INFO, MSGTR_MPCODECS_OutputWithFourccNotSupported, fmt);
 	mux_v->bih->biCompression = 0;
 	return 0;
     }

Index: ve_vfw.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/ve_vfw.c,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -r1.23 -r1.24
--- ve_vfw.c	27 Mar 2006 07:22:47 -0000	1.23
+++ ve_vfw.c	31 Mar 2006 00:15:47 -0000	1.24
@@ -8,6 +8,7 @@
 #ifdef USE_WIN32DLL
 
 #include "mp_msg.h"
+#include "help_mp.h"
 
 #include "codec-cfg.h"
 //#include "stream.h"
@@ -66,34 +67,34 @@
     mp_msg(MSGT_WIN32,MSGL_ERR,"ICOpen failed! unknown codec / wrong parameters?\n");
     return NULL;
   }
-  printf("HIC: %x\n", encoder_hic);
+  mp_msg(MSGT_WIN32,MSGL_INFO,"HIC: %x\n", encoder_hic);
 
 #if 1
 {
   ICINFO icinfo;
 
   ret = ICGetInfo(encoder_hic, &icinfo, sizeof(ICINFO));
-  printf("%ld - %ld - %d\n", ret, icinfo.dwSize, sizeof(ICINFO));
-printf("Compressor type: %.4lx\n", icinfo.fccType);
-printf("Compressor subtype: %.4lx\n", icinfo.fccHandler);
-printf("Compressor flags: %lu, version %lu, ICM version: %lu\n",
+  mp_msg(MSGT_WIN32,MSGL_INFO,"%ld - %ld - %d\n", ret, icinfo.dwSize, sizeof(ICINFO));
+  mp_msg(MSGT_WIN32,MSGL_INFO,MSGTR_MPCODECS_CompressorType, icinfo.fccType);
+  mp_msg(MSGT_WIN32,MSGL_INFO,MSGTR_MPCODECS_CompressorSubtype, icinfo.fccHandler);
+  mp_msg(MSGT_WIN32,MSGL_INFO,MSGTR_MPCODECS_CompressorFlags,
     icinfo.dwFlags, icinfo.dwVersion, icinfo.dwVersionICM);
 //printf("Compressor name: %s\n", icinfo.szName);
 //printf("Compressor description: %s\n", icinfo.szDescription);
 
-printf("Flags:");
+mp_msg(MSGT_WIN32,MSGL_INFO,MSGTR_MPCODECS_Flags);
 if (icinfo.dwFlags & VIDCF_QUALITY)
-    printf(" quality");
+    mp_msg(MSGT_WIN32,MSGL_INFO,MSGTR_MPCODECS_Quality);
 if (icinfo.dwFlags & VIDCF_FASTTEMPORALD)
-    printf(" fast-decompr");
+    mp_msg(MSGT_WIN32,MSGL_INFO," fast-decompr");
 if (icinfo.dwFlags & VIDCF_QUALITYTIME)
-    printf(" temp-quality");
-printf("\n");
+    mp_msg(MSGT_WIN32,MSGL_INFO," temp-quality");
+mp_msg(MSGT_WIN32,MSGL_INFO,"\n");
 }
 #endif
 
   temp_len = ICCompressGetFormatSize(encoder_hic, input_bih);
-  printf("ICCompressGetFormatSize ret: %d\n", temp_len);
+  mp_msg(MSGT_WIN32,MSGL_INFO,"ICCompressGetFormatSize ret: %d\n", temp_len);
 
   if (temp_len < sizeof(BITMAPINFOHEADER)) temp_len=sizeof(BITMAPINFOHEADER);
 
@@ -161,16 +162,15 @@
     mp_msg(MSGT_WIN32,MSGL_ERR,"ICCompressBegin failed: Error %d\n", (int)ret);
 //    return 0;
   } else
-  mp_msg(MSGT_WIN32,MSGL_V,"ICCompressBegin OK\n");
-
-    printf(" Output format after query/begin:\n");
-	printf("  biSize %d\n", output_bih->biSize);
-	printf("  biWidth %d\n", output_bih->biWidth);
-	printf("  biHeight %d\n", output_bih->biHeight);
-	printf("  biPlanes %d\n", output_bih->biPlanes);
-	printf("  biBitCount %d\n", output_bih->biBitCount);
-	printf("  biCompression 0x%x ('%.4s')\n", output_bih->biCompression, (char *)&output_bih->biCompression);
-	printf("  biSizeImage %d\n", output_bih->biSizeImage);
+    mp_msg(MSGT_WIN32,MSGL_V,"ICCompressBegin OK\n");
+    mp_msg(MSGT_WIN32,MSGL_INFO," Output format after query/begin:\n");
+    mp_msg(MSGT_WIN32,MSGL_INFO,"  biSize %d\n", output_bih->biSize);
+    mp_msg(MSGT_WIN32,MSGL_INFO,"  biWidth %d\n", output_bih->biWidth);
+    mp_msg(MSGT_WIN32,MSGL_INFO,"  biHeight %d\n", output_bih->biHeight);
+    mp_msg(MSGT_WIN32,MSGL_INFO,"  biPlanes %d\n", output_bih->biPlanes);
+    mp_msg(MSGT_WIN32,MSGL_INFO,"  biBitCount %d\n", output_bih->biBitCount);
+    mp_msg(MSGT_WIN32,MSGL_INFO,"  biCompression 0x%x ('%.4s')\n", output_bih->biCompression, (char *)&output_bih->biCompression);
+    mp_msg(MSGT_WIN32,MSGL_INFO,"  biSizeImage %d\n", output_bih->biSizeImage);
   
   encoder_buf_size=input_bih->biSizeImage;
   encoder_buf=malloc(encoder_buf_size);
@@ -270,7 +270,7 @@
 
     if (!vfw_param_codec)
     {
-	printf("No VfW codec specified! It's required!\n");
+	mp_msg(MSGT_WIN32,MSGL_WARN, MSGTR_MPCODECS_NoVfwCodecSpecified);
 	return 0;
     }
 //    mux_v->bih=vfw_open_encoder("divxc32.dll",vfw_bih,mmioFOURCC('D', 'I', 'V', '3'));

Index: vf.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/vf.c,v
retrieving revision 1.125
retrieving revision 1.126
diff -u -r1.125 -r1.126
--- vf.c	21 Mar 2006 21:26:40 -0000	1.125
+++ vf.c	31 Mar 2006 00:15:47 -0000	1.126
@@ -318,7 +318,7 @@
 		// need to re-allocate buffer memory:
 		free(mpi->planes[0]);
 		mpi->flags&=~MP_IMGFLAG_ALLOCATED;
-		printf("vf.c: have to REALLOCATE buffer memory :(\n");
+		mp_msg(MSGT_VFILTER,MSGL_V,"vf.c: have to REALLOCATE buffer memory :(\n");
 	    }
 //	} else {
 	} {

Index: vf_crop.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/vf_crop.c,v
retrieving revision 1.19
retrieving revision 1.20
diff -u -r1.19 -r1.20
--- vf_crop.c	21 Mar 2006 21:26:41 -0000	1.19
+++ vf_crop.c	31 Mar 2006 00:15:47 -0000	1.20
@@ -4,6 +4,7 @@
 
 #include "config.h"
 #include "mp_msg.h"
+#include "help_mp.h"
 
 #include "img_format.h"
 #include "mp_image.h"
@@ -57,7 +58,7 @@
     // check:
     if(vf->priv->crop_w+vf->priv->crop_x>width ||
        vf->priv->crop_h+vf->priv->crop_y>height){
-	printf("crop: bad position/width/height - cropped area is out of the original!\n");
+	mp_msg(MSGT_VFILTER, MSGL_WARN, MSGTR_MPCODECS_CropBadPositionWidthHeight);
 	return 0;
     }
     if(!opt_screen_size_x && !opt_screen_size_y){

Index: vf_cropdetect.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/vf_cropdetect.c,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -r1.14 -r1.15
--- vf_cropdetect.c	21 Mar 2006 21:26:41 -0000	1.14
+++ vf_cropdetect.c	31 Mar 2006 00:15:47 -0000	1.15
@@ -5,6 +5,7 @@
 
 #include "config.h"
 #include "mp_msg.h"
+#include "help_mp.h"
 
 #include "img_format.h"
 #include "mp_image.h"
@@ -127,7 +128,7 @@
     h -= shrink_by;
     y += (shrink_by / 2 + 1) & ~1;
 
-    printf("crop area: X: %d..%d  Y: %d..%d  (-vf crop=%d:%d:%d:%d)\n",
+    mp_msg(MSGT_VFILTER, MSGL_INFO, MSGTR_MPCODECS_CropArea,
 	vf->priv->x1,vf->priv->x2,
 	vf->priv->y1,vf->priv->y2,
 	w,h,x,y);

Index: vf_expand.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/vf_expand.c,v
retrieving revision 1.35
retrieving revision 1.36
diff -u -r1.35 -r1.36
--- vf_expand.c	21 Mar 2006 21:26:41 -0000	1.35
+++ vf_expand.c	31 Mar 2006 00:15:47 -0000	1.36
@@ -6,6 +6,7 @@
 
 #include "config.h"
 #include "mp_msg.h"
+#include "help_mp.h"
 
 #include "img_format.h"
 #include "mp_image.h"
@@ -232,7 +233,7 @@
 #if 1
 	if((vf->dmpi->flags & MP_IMGFLAG_DRAW_CALLBACK) &&
 	  !(vf->dmpi->flags & MP_IMGFLAG_DIRECT)){
-	    printf("Full DR not possible, trying SLICES instead!\n");
+	    mp_msg(MSGT_VFILTER, MSGL_INFO, MSGTR_MPCODECS_FullDRNotPossible);
 	    return;
 	}
 #endif
@@ -273,7 +274,7 @@
             MAX(vf->priv->exp_w, mpi->width +vf->priv->exp_x), 
             MAX(vf->priv->exp_h, mpi->height+vf->priv->exp_y));
     if(!(vf->dmpi->flags&MP_IMGFLAG_DRAW_CALLBACK))
-	printf("WARNING! next filter doesn't support SLICES, get ready for sig11...\n"); // shouldn't happen.
+	mp_msg(MSGT_VFILTER, MSGL_WARN, MSGTR_MPCODECS_WarnNextFilterDoesntSupportSlices); // shouldn't happen.
     vf->priv->first_slice = 1;
 }
 
@@ -332,7 +333,7 @@
 static int put_image(struct vf_instance_s* vf, mp_image_t *mpi, double pts){
     if(mpi->flags&MP_IMGFLAG_DIRECT || mpi->flags&MP_IMGFLAG_DRAW_CALLBACK){
 	vf->dmpi=mpi->priv;
-	if(!vf->dmpi) { printf("Why do we get NULL \n"); return 0; }
+	if(!vf->dmpi) { mp_msg(MSGT_VFILTER, MSGL_WARN, MSGTR_MPCODECS_FunWhydowegetNULL); return 0; }
 	mpi->priv=NULL;
 #ifdef OSD_SUPPORT
 	if(vf->priv->osd) draw_osd(vf,mpi->w,mpi->h);

Index: vf_fame.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/vf_fame.c,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -r1.13 -r1.14
--- vf_fame.c	21 Mar 2006 21:26:41 -0000	1.13
+++ vf_fame.c	31 Mar 2006 00:15:47 -0000	1.14
@@ -5,6 +5,7 @@
 
 #include "config.h"
 #include "mp_msg.h"
+#include "help_mp.h"
 
 //#ifdef USE_LIBFAME
 
@@ -103,7 +104,7 @@
 
     vf->priv->ctx=fame_open();
     if(!vf->priv->ctx){
-	printf("FATAL: cannot open libFAME!\n");
+	mp_msg(MSGT_VFILTER, MSGL_ERR, MSGTR_MPCODECS_FatalCantOpenlibFAME);
 	return 0;
     }
 

Index: vf_format.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/vf_format.c,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -r1.13 -r1.14
--- vf_format.c	18 Nov 2005 14:39:23 -0000	1.13
+++ vf_format.c	31 Mar 2006 00:15:47 -0000	1.14
@@ -5,6 +5,7 @@
 
 #include "config.h"
 #include "mp_msg.h"
+#include "help_mp.h"
 
 #include "img_format.h"
 #include "mp_image.h"
@@ -65,7 +66,7 @@
 	if(!strcasecmp(args,"argb")) vf->priv->fmt=IMGFMT_ARGB; else
 	if(!strcasecmp(args,"bgra")) vf->priv->fmt=IMGFMT_BGRA; else
 	if(!strcasecmp(args,"abgr")) vf->priv->fmt=IMGFMT_ABGR; else
-	{ printf("Unknown format name: '%s'\n",args);return 0;}
+	{ mp_msg(MSGT_VFILTER, MSGL_WARN, MSGTR_MPCODECS_UnknownFormatName, args);return 0;}
     }
         
 

Index: vf_framestep.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/vf_framestep.c,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- vf_framestep.c	21 Mar 2006 21:26:41 -0000	1.3
+++ vf_framestep.c	31 Mar 2006 00:15:47 -0000	1.4
@@ -53,6 +53,7 @@
 
 #include "config.h"
 #include "mp_msg.h"
+#include "help_mp.h"
 #include "cpudetect.h"
 
 #include "img_format.h"
@@ -88,7 +89,7 @@
      */
     if (priv->dump_iframe) {
         if (mpi->pict_type == 1) {
-            printf("I!\n");
+            mp_msg(MSGT_VFILTER, MSGL_INFO, "I!\n");
         }
     }
 
@@ -172,7 +173,7 @@
                 if (*args != '\0') {
                     p->frame_step = atoi(args);
                     if (p->frame_step <= 0) {
-                        printf("Error parsing argument\n");
+                        mp_msg(MSGT_VFILTER, MSGL_WARN, MSGTR_MPCODECS_ErrorParsingArgument);
                         return(0);
                     }
                 }

Index: vf_noformat.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/vf_noformat.c,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- vf_noformat.c	18 Nov 2005 14:39:24 -0000	1.3
+++ vf_noformat.c	31 Mar 2006 00:15:47 -0000	1.4
@@ -5,6 +5,7 @@
 
 #include "config.h"
 #include "mp_msg.h"
+#include "help_mp.h"
 
 #include "img_format.h"
 #include "mp_image.h"
@@ -65,7 +66,7 @@
 	if(!strcasecmp(args,"argb")) vf->priv->fmt=IMGFMT_ARGB; else
 	if(!strcasecmp(args,"bgra")) vf->priv->fmt=IMGFMT_BGRA; else
 	if(!strcasecmp(args,"abgr")) vf->priv->fmt=IMGFMT_ABGR; else
-	{ printf("Unknown format name: '%s'\n",args);return 0;}
+	{ mp_msg(MSGT_VFILTER, MSGL_WARN, MSGTR_MPCODECS_UnknownFormatName, args);return 0;}
     }
         
 

Index: vf_palette.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/vf_palette.c,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -r1.14 -r1.15
--- vf_palette.c	21 Mar 2006 21:26:41 -0000	1.14
+++ vf_palette.c	31 Mar 2006 00:15:47 -0000	1.15
@@ -5,6 +5,7 @@
 
 #include "config.h"
 #include "mp_msg.h"
+#include "help_mp.h"
 
 #include "img_format.h"
 #include "mp_image.h"
@@ -187,7 +188,7 @@
 	if (!strcasecmp(args,"bgr24")) vf->priv->fmt=IMGFMT_BGR24; else
 	if (!strcasecmp(args,"bgr32")) vf->priv->fmt=IMGFMT_BGR32; else
 	{
-	    printf("Unknown forced format name: '%s'\n", args);
+	    mp_msg(MSGT_VFILTER, MSGL_WARN, MSGTR_MPCODECS_UnknownFormatName, args);
 	    return(0);
 	}
     }

Index: vf_phase.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/vf_phase.c,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- vf_phase.c	27 Mar 2006 07:22:47 -0000	1.6
+++ vf_phase.c	31 Mar 2006 00:15:47 -0000	1.7
@@ -168,11 +168,11 @@
 
    if( mp_msg_test(MSGT_VFILTER,MSGL_V) )
       {
-      printf("%c", mode==BOTTOM_FIRST?'b':mode==TOP_FIRST?'t':'p');
-      if(tdiff==65536.0) printf("     N/A "); else printf(" %8.2f", tdiff);
-      if(bdiff==65536.0) printf("     N/A "); else printf(" %8.2f", bdiff);
-      if(pdiff==65536.0) printf("     N/A "); else printf(" %8.2f", pdiff);
-      printf("        \n");
+      mp_msg(MSGT_VFILTER, MSGL_INFO, "%c", mode==BOTTOM_FIRST?'b':mode==TOP_FIRST?'t':'p');
+      if(tdiff==65536.0) mp_msg(MSGT_VFILTER, MSGL_INFO,"     N/A "); else mp_msg(MSGT_VFILTER, MSGL_INFO," %8.2f", tdiff);
+      if(bdiff==65536.0) mp_msg(MSGT_VFILTER, MSGL_INFO,"     N/A "); else mp_msg(MSGT_VFILTER, MSGL_INFO," %8.2f", bdiff);
+      if(pdiff==65536.0) mp_msg(MSGT_VFILTER, MSGL_INFO,"     N/A "); else mp_msg(MSGT_VFILTER, MSGL_INFO," %8.2f", pdiff);
+      mp_msg(MSGT_VFILTER, MSGL_INFO,"        \n");
       }
 
    return mode;

Index: vf_test.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/vf_test.c,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -r1.9 -r1.10
--- vf_test.c	21 Mar 2006 21:26:42 -0000	1.9
+++ vf_test.c	31 Mar 2006 00:15:47 -0000	1.10
@@ -23,6 +23,7 @@
 
 #include "config.h"
 #include "mp_msg.h"
+#include "help_mp.h"
 
 #include "img_format.h"
 #include "mp_image.h"
@@ -51,7 +52,7 @@
 	unsigned int flags, unsigned int outfmt){
 
     if(vf_next_query_format(vf,IMGFMT_YV12)<=0){
-	printf("yv12 not supported by next filter/vo :(\n");
+	mp_msg(MSGT_VFILTER, MSGL_WARN, MSGTR_MPCODECS_WarnNextFilterDoesntSupport, "YV12");
 	return 0;
     }
 

Index: vf_tile.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/vf_tile.c,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- vf_tile.c	27 Mar 2006 07:22:47 -0000	1.4
+++ vf_tile.c	31 Mar 2006 00:15:47 -0000	1.5
@@ -39,6 +39,7 @@
 
 #include "config.h"
 #include "mp_msg.h"
+#include "help_mp.h"
 #include "cpudetect.h"
 
 #include "img_format.h"
@@ -278,7 +279,7 @@
 //    er |= parse_int( &args, &p->bkgSet, 0 );
 
     if (er) {
-        printf("Error parsing argument\n");
+        mp_msg(MSGT_VFILTER, MSGL_ERR, MSGTR_MPCODECS_ErrorParsingArgument);
         return(0);
     }
     /* Load some default */

Index: vf_yuy2.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/vf_yuy2.c,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -r1.10 -r1.11
--- vf_yuy2.c	21 Mar 2006 21:26:42 -0000	1.10
+++ vf_yuy2.c	31 Mar 2006 00:15:47 -0000	1.11
@@ -5,6 +5,7 @@
 
 #include "config.h"
 #include "mp_msg.h"
+#include "help_mp.h"
 
 #include "img_format.h"
 #include "mp_image.h"
@@ -23,7 +24,7 @@
     sws_rgb2rgb_init(get_sws_cpuflags());
     
     if(vf_next_query_format(vf,IMGFMT_YUY2)<=0){
-	printf("yuy2 not supported by next filter/vo :(\n");
+	mp_msg(MSGT_VFILTER, MSGL_WARN, MSGTR_MPCODECS_WarnNextFilterDoesntSupport, "YUY2");
 	return 0;
     }
     

Index: vf_yvu9.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/vf_yvu9.c,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -r1.8 -r1.9
--- vf_yvu9.c	21 Mar 2006 21:26:42 -0000	1.8
+++ vf_yvu9.c	31 Mar 2006 00:15:47 -0000	1.9
@@ -5,6 +5,7 @@
 
 #include "config.h"
 #include "mp_msg.h"
+#include "help_mp.h"
 
 #include "img_format.h"
 #include "mp_image.h"
@@ -20,7 +21,7 @@
 	unsigned int flags, unsigned int outfmt){
     
     if(vf_next_query_format(vf,IMGFMT_YV12)<=0){
-	printf("yv12 not supported by next filter/vo :(\n");
+	mp_msg(MSGT_VFILTER, MSGL_WARN, MSGTR_MPCODECS_WarnNextFilterDoesntSupport, "YVU9");
 	return 0;
     }
     




More information about the MPlayer-cvslog mailing list