Removed variables that current GCC builds warn on as set and never used.
--HG-- branch : SDL-1.2
This commit is contained in:
parent
14524755f2
commit
ab7eddb38c
6 changed files with 12 additions and 14 deletions
|
@ -47,7 +47,6 @@ static struct MS_ADPCM_decoder {
|
|||
static int InitMS_ADPCM(WaveFMT *format)
|
||||
{
|
||||
Uint8 *rogue_feel;
|
||||
Uint16 extra_info;
|
||||
int i;
|
||||
|
||||
/* Set the rogue pointer to the MS_ADPCM specific data */
|
||||
|
@ -60,7 +59,6 @@ static int InitMS_ADPCM(WaveFMT *format)
|
|||
SDL_SwapLE16(format->bitspersample);
|
||||
rogue_feel = (Uint8 *)format+sizeof(*format);
|
||||
if ( sizeof(*format) == 16 ) {
|
||||
extra_info = ((rogue_feel[1]<<8)|rogue_feel[0]);
|
||||
rogue_feel += sizeof(Uint16);
|
||||
}
|
||||
MS_ADPCM_state.wSamplesPerBlock = ((rogue_feel[1]<<8)|rogue_feel[0]);
|
||||
|
@ -227,7 +225,6 @@ static struct IMA_ADPCM_decoder {
|
|||
static int InitIMA_ADPCM(WaveFMT *format)
|
||||
{
|
||||
Uint8 *rogue_feel;
|
||||
Uint16 extra_info;
|
||||
|
||||
/* Set the rogue pointer to the IMA_ADPCM specific data */
|
||||
IMA_ADPCM_state.wavefmt.encoding = SDL_SwapLE16(format->encoding);
|
||||
|
@ -239,7 +236,6 @@ static int InitIMA_ADPCM(WaveFMT *format)
|
|||
SDL_SwapLE16(format->bitspersample);
|
||||
rogue_feel = (Uint8 *)format+sizeof(*format);
|
||||
if ( sizeof(*format) == 16 ) {
|
||||
extra_info = ((rogue_feel[1]<<8)|rogue_feel[0]);
|
||||
rogue_feel += sizeof(Uint16);
|
||||
}
|
||||
IMA_ADPCM_state.wSamplesPerBlock = ((rogue_feel[1]<<8)|rogue_feel[0]);
|
||||
|
|
|
@ -1645,9 +1645,8 @@ static int RLEColorkeySurface(SDL_Surface *surface)
|
|||
Uint8 *rlebuf, *dst;
|
||||
int maxn;
|
||||
int y;
|
||||
Uint8 *srcbuf, *curbuf, *lastline;
|
||||
Uint8 *srcbuf, *lastline;
|
||||
int maxsize = 0;
|
||||
int skip, run;
|
||||
int bpp = surface->format->BytesPerPixel;
|
||||
getpix_func getpix;
|
||||
Uint32 ckey, rgbmask;
|
||||
|
@ -1681,9 +1680,7 @@ static int RLEColorkeySurface(SDL_Surface *surface)
|
|||
|
||||
/* Set up the conversion */
|
||||
srcbuf = (Uint8 *)surface->pixels;
|
||||
curbuf = srcbuf;
|
||||
maxn = bpp == 4 ? 65535 : 255;
|
||||
skip = run = 0;
|
||||
dst = rlebuf;
|
||||
rgbmask = ~surface->format->Amask;
|
||||
ckey = surface->format->colorkey & rgbmask;
|
||||
|
|
|
@ -132,6 +132,17 @@ SDL_Surface * SDL_LoadBMP_RW (SDL_RWops *src, int freesrc)
|
|||
biClrUsed = SDL_ReadLE32(src);
|
||||
biClrImportant = SDL_ReadLE32(src);
|
||||
}
|
||||
|
||||
/* stop some compiler warnings. */
|
||||
(void) bfSize;
|
||||
(void) bfReserved1;
|
||||
(void) bfReserved2;
|
||||
(void) biPlanes;
|
||||
(void) biSizeImage;
|
||||
(void) biXPelsPerMeter;
|
||||
(void) biYPelsPerMeter;
|
||||
(void) biClrImportant;
|
||||
|
||||
if (biHeight < 0) {
|
||||
topDown = SDL_TRUE;
|
||||
biHeight = -biHeight;
|
||||
|
|
|
@ -205,7 +205,6 @@ int SDL_SoftStretch(SDL_Surface *src, SDL_Rect *srcrect,
|
|||
int src_locked;
|
||||
int dst_locked;
|
||||
int pos, inc;
|
||||
int dst_width;
|
||||
int dst_maxrow;
|
||||
int src_row, dst_row;
|
||||
Uint8 *srcp = NULL;
|
||||
|
@ -282,7 +281,6 @@ int SDL_SoftStretch(SDL_Surface *src, SDL_Rect *srcrect,
|
|||
inc = (srcrect->h << 16) / dstrect->h;
|
||||
src_row = srcrect->y;
|
||||
dst_row = dstrect->y;
|
||||
dst_width = dstrect->w*bpp;
|
||||
|
||||
#ifdef USE_ASM_STRETCH
|
||||
/* Write the opcodes for this stretch */
|
||||
|
|
|
@ -96,7 +96,6 @@ static int HWAccelBlit(SDL_Surface *src, SDL_Rect *srcrect,
|
|||
SDL_VideoDevice *this = current_video;
|
||||
int bpp;
|
||||
Uint32 src_format;
|
||||
Uint32 dst_format;
|
||||
Uint32 src_base;
|
||||
Uint32 dst_base;
|
||||
int srcX, srcY;
|
||||
|
@ -118,7 +117,6 @@ static int HWAccelBlit(SDL_Surface *src, SDL_Rect *srcrect,
|
|||
src_format = src->pitch | ((bpp+((bpp==8) ? 0 : 8)) << 13);
|
||||
dst_base = ((char *)dst->pixels - mapped_mem);
|
||||
bpp = dst->format->BitsPerPixel;
|
||||
dst_format = dst->pitch | ((bpp+((bpp==8) ? 0 : 8)) << 13);
|
||||
|
||||
srcX = srcrect->x;
|
||||
srcY = srcrect->y;
|
||||
|
|
|
@ -102,13 +102,11 @@ int X11_SetupImage(_THIS, SDL_Surface *screen)
|
|||
if(!use_mitshm)
|
||||
#endif /* not NO_SHARED_MEMORY */
|
||||
{
|
||||
int bpp;
|
||||
screen->pixels = SDL_malloc(screen->h*screen->pitch);
|
||||
if ( screen->pixels == NULL ) {
|
||||
SDL_OutOfMemory();
|
||||
return -1;
|
||||
}
|
||||
bpp = screen->format->BytesPerPixel;
|
||||
SDL_Ximage = XCreateImage(SDL_Display, SDL_Visual,
|
||||
this->hidden->depth, ZPixmap, 0,
|
||||
(char *)screen->pixels,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue