[MPlayer-cvslog] r23452 - in trunk/mp3lib: decode_MMX.c decode_i586.c layer3.c mpg123.h sr1.c tabinit.c
Alex Beregszaszi
alex at rtfs.hu
Sat Jun 2 22:10:15 CEST 2007
Hi,
> Log:
> Use int and uint32_t instead of long and unsigned long, when appropriate.
> Modified: trunk/mp3lib/sr1.c
> ==============================================================================
> --- trunk/mp3lib/sr1.c (original)
> +++ trunk/mp3lib/sr1.c Sat Jun 2 18:25:18 2007
> @@ -108,11 +108,11 @@ static int tabsel_123[2][3][16] = {
> {0,8,16,24,32,40,48,56,64,80,96,112,128,144,160,} }
> };
>
> -static long freqs[9] = { 44100, 48000, 32000, 22050, 24000, 16000 , 11025 , 12000 , 8000 };
> +static int freqs[9] = { 44100, 48000, 32000, 22050, 24000, 16000 , 11025 , 12000 , 8000 };
>
> LOCAL unsigned int getbits(short number_of_bits)
> {
> - unsigned long rval;
> + unsigned rval;
Whats that?
> // if(MP3_frames>=7741) printf("getbits: bits=%d bitsleft=%d wordptr=%x\n",number_of_bits,bitsleft,wordpointer);
> if((bitsleft-=number_of_bits)<0) return 0;
> if(!number_of_bits) return 0;
> @@ -133,12 +133,12 @@ LOCAL unsigned int getbits(short number_
>
> LOCAL unsigned int getbits_fast(short number_of_bits)
> {
> - unsigned long rval;
> + unsigned rval;
Ditto.
> // if(MP3_frames>=7741) printf("getbits_fast: bits=%d bitsleft=%d wordptr=%x\n",number_of_bits,bitsleft,wordpointer);
> if((bitsleft-=number_of_bits)<0) return 0;
> if(!number_of_bits) return 0;
> #if defined(CAN_COMPILE_X86_ASM)
> - rval = bswap_16(*((unsigned short *)wordpointer));
> + rval = bswap_16(*((uint16_t *)wordpointer));
> #else
> /*
> * we may not be able to address unaligned 16-bit data on non-x86 cpus.
--
Alex Beregszaszi
More information about the MPlayer-cvslog
mailing list