[MPlayer-dev-eng] [PATCH] printf --> mp_msg transition (mplayer.c)

Diego Biurrun diego at biurrun.de
Wed Oct 6 17:37:00 CEST 2004


The Wanderer writes:
> 
> The attached patch does several things:
> 
> Moves all (apparently) translation-appropriate messages from mplayer.c
> to help/help_mp-en.h.

OK

> Moves one message from help/help_mp-en.h back to mencoder.c, because it
> should not have been moved in the first place.

OK

> Adds trailing periods to a few strings; may also correct a few spelling
> errors, but I don't think I left anything like that in this version of
> the patch.

Ideally, this would go in a separate patch.  But I'm not going to be
too pedantic about this.

> There are two MSGTRs of MSGL_V (AODescription_AOAuthor, AOComment) in
> mplayer.c which were present before I did my work; for the moment, I've
> left them alone. If I come across such things, which I would not
> ordinarily change but which are inconsistent with the rules I'm
> following, should I correct them as well?

Yes.

> -      mp_msg(MSGT_CPLAYER, MSGL_INFO, "Using %s timing\n",
> +      mp_msg(MSGT_CPLAYER, MSGL_INFO, MSGTR_UsingTimingType, //This will break translations unless the fourth parameter is also translated. FIXME
>  	     softsleep?"software":timer_name);

I think the easiest solution here is to move this message to MSGL_V
and make MPlayer a bit less verbose in the process.  In fact, if
nobody objects I will do just that.

> -       edl_mute_count++; // new EDL seek behavior needs this
> +       edl_mute_count++; // new EDL seek behavior need this

This was correct before.

> @@ -323,7 +361,6 @@
>  #define MSGTR_LavcAudioCodecNotFound "Audio LAVC, couldn't find encoder for codec %s\n"
>  #define MSGTR_CouldntAllocateLavcContext "Audio LAVC, couldn't allocate context!\n"
>  #define MSGTR_CouldntOpenCodec "Couldn't open codec %s, br=%d\n"
> -#define MSGTR_FramesizeBufsizeTag "FRAME_SIZE: %d, BUFFER_SIZE: %d, TAG: 0x%x\n"

Ideally, if you remove a message, you should remove it from all
translations as well to avoid cruft from piling up.

Diego




More information about the MPlayer-dev-eng mailing list