# HG changeset patch # User gpoirier # Date 1162809354 0 # Node ID dc1ff57e1b08281c91b381c7d6516f79924e4934 # Parent ccae536736924d83bab05f2d65e61e193218045a woops, fix missplaced doxy comment diff -r ccae53673692 -r dc1ff57e1b08 common.h --- a/common.h Mon Nov 06 10:32:48 2006 +0000 +++ b/common.h Mon Nov 06 10:35:54 2006 +0000 @@ -322,6 +322,21 @@ #define MKTAG(a,b,c,d) (a | (b << 8) | (c << 16) | (d << 24)) #define MKBETAG(a,b,c,d) (d | (c << 8) | (b << 16) | (a << 24)) +#define GET_UTF8(val, GET_BYTE, ERROR)\ + val= GET_BYTE;\ + {\ + int ones= 7 - av_log2(val ^ 255);\ + if(ones==1)\ + ERROR\ + val&= 127>>ones;\ + while(--ones > 0){\ + int tmp= GET_BYTE - 128;\ + if(tmp>>6)\ + ERROR\ + val= (val<<6) + tmp;\ + }\ + } + /*! * \def PUT_UTF8(val, GET_BYTE, ERROR) * converts a 32-bit unicode character to its utf-8 encoded form (up to 6 bytes long). @@ -337,21 +352,6 @@ * executed up to 6 times, depending on the length of the converted * unicode character. */ -#define GET_UTF8(val, GET_BYTE, ERROR)\ - val= GET_BYTE;\ - {\ - int ones= 7 - av_log2(val ^ 255);\ - if(ones==1)\ - ERROR\ - val&= 127>>ones;\ - while(--ones > 0){\ - int tmp= GET_BYTE - 128;\ - if(tmp>>6)\ - ERROR\ - val= (val<<6) + tmp;\ - }\ - } - #define PUT_UTF8(val, tmp, PUT_BYTE)\ {\ int bytes, shift;\