[FFmpeg-devel] Suggestion for a centralized language-tag facility in libavformat
Diego Biurrun
diego
Wed Apr 15 13:57:06 CEST 2009
On Tue, Apr 14, 2009 at 10:18:42PM +0200, cyril comparon wrote:
> Gee I didn't know I was _such_ a lousy developer!
> However, I was not excepting my patch to be applied as-is, since
> deeper reflection may be needed before adding this new facility.
>
> --- Changelog (revision 18511)
> +++ Changelog (working copy)
> @@ -1,5 +1,6 @@
> version <next>:
>
> +- introduced avlanguage helpers in libavformat
> - PB-frame decoding for H.263
> - deprecated vhook subsystem removed
> - deprecated old scaler removed
The changelog is sorted the other way around. I added an explanatory
note.
> --- libavformat/avlanguage.c (revision 0)
> +++ libavformat/avlanguage.c (revision 0)
> @@ -0,0 +1,577 @@
> +
> +static int priv_rowByISO6392(const char *lang)
> +{
> + int i;
> + if (lang)
> + for (i=0; languageTable[i].iso6392bibl[0] != '\0'; i++)
> + if (!strcmp(lang, languageTable[i].iso6392bibl) || !strcmp(lang, languageTable[i].iso6392term))
> + return i;
> + return -1;
> +}
> +
> +/**
> + * Returns the 2-letters ISO639-1 code associated with a given 3-letters ISO639-2 code,
3-letter, same below
Please keep lines below 80 characters where sensibly possible.
Diego
More information about the ffmpeg-devel
mailing list