From 08c678908c33f995d11425a2cd55ca7452076a4c Mon Sep 17 00:00:00 2001 From: avolkov Date: Fri, 18 Dec 2009 23:18:28 +0000 Subject: [PATCH] Cleanup: removed unused TFB_Image.Palette git-svn-id: svn://svn.code.sf.net/p/sc2/code/trunk@3439 8092fc87-c524-0410-9efc-e669fe64eaf9 --- sc2/src/libs/graphics/tfb_draw.c | 8 +------- sc2/src/libs/graphics/tfb_draw.h | 1 - 2 files changed, 1 insertion(+), 8 deletions(-) diff --git a/sc2/src/libs/graphics/tfb_draw.c b/sc2/src/libs/graphics/tfb_draw.c index 1c693561e..3285e24ef 100644 --- a/sc2/src/libs/graphics/tfb_draw.c +++ b/sc2/src/libs/graphics/tfb_draw.c @@ -299,9 +299,7 @@ TFB_DrawImage_New (TFB_Canvas canvas) img->last_scale = 0; TFB_DrawCanvas_GetExtent (canvas, &img->extent); - img->Palette = TFB_DrawCanvas_ExtractPalette (canvas); - - if (img->Palette) + if (TFB_DrawCanvas_IsPaletted (canvas)) { img->NormalImg = canvas; } @@ -328,7 +326,6 @@ TFB_DrawImage_CreateForScreen (int w, int h, BOOLEAN withalpha) img->last_scale_hs = NullHs; img->last_scale_type = -1; img->last_scale = 0; - img->Palette = NULL; img->extent.width = w; img->extent.height = h; @@ -417,9 +414,6 @@ TFB_DrawImage_Delete (TFB_Image *image) TFB_DrawCanvas_Delete (image->ScaledImg); } - if (image->Palette) - HFree (image->Palette); - UnlockMutex (image->mutex); DestroyMutex (image->mutex); diff --git a/sc2/src/libs/graphics/tfb_draw.h b/sc2/src/libs/graphics/tfb_draw.h index 31109b1c0..9903cabf9 100644 --- a/sc2/src/libs/graphics/tfb_draw.h +++ b/sc2/src/libs/graphics/tfb_draw.h @@ -41,7 +41,6 @@ typedef struct tfb_image TFB_Canvas ScaledImg; TFB_Canvas MipmapImg; TFB_Canvas FilledImg; - Color *Palette; int colormap_index; int colormap_version; HOT_SPOT NormalHs;