Finally removing SETPALETTE draw command. We have not been using it for a really long time
git-svn-id: svn://svn.code.sf.net/p/sc2/code/trunk@2841 8092fc87-c524-0410-9efc-e669fe64eaf9
This commit is contained in:
@@ -35,7 +35,6 @@ enum
|
|||||||
TFB_DRAWCOMMANDTYPE_SCISSORENABLE,
|
TFB_DRAWCOMMANDTYPE_SCISSORENABLE,
|
||||||
TFB_DRAWCOMMANDTYPE_SCISSORDISABLE,
|
TFB_DRAWCOMMANDTYPE_SCISSORDISABLE,
|
||||||
|
|
||||||
TFB_DRAWCOMMANDTYPE_SETPALETTE,
|
|
||||||
TFB_DRAWCOMMANDTYPE_SETMIPMAP,
|
TFB_DRAWCOMMANDTYPE_SETMIPMAP,
|
||||||
TFB_DRAWCOMMANDTYPE_DELETEIMAGE,
|
TFB_DRAWCOMMANDTYPE_DELETEIMAGE,
|
||||||
TFB_DRAWCOMMANDTYPE_DELETEDATA,
|
TFB_DRAWCOMMANDTYPE_DELETEDATA,
|
||||||
|
|||||||
@@ -51,8 +51,6 @@ static volatile BOOLEAN abortFlag = FALSE;
|
|||||||
|
|
||||||
int GfxFlags = 0;
|
int GfxFlags = 0;
|
||||||
|
|
||||||
static TFB_Palette palette[256];
|
|
||||||
|
|
||||||
TFB_GRAPHICS_BACKEND *graphics_backend = NULL;
|
TFB_GRAPHICS_BACKEND *graphics_backend = NULL;
|
||||||
|
|
||||||
#define FPS_PERIOD 100
|
#define FPS_PERIOD 100
|
||||||
@@ -693,22 +691,6 @@ TFB_FlushGraphics (void) // Only call from main thread!!
|
|||||||
|
|
||||||
switch (DC.Type)
|
switch (DC.Type)
|
||||||
{
|
{
|
||||||
case TFB_DRAWCOMMANDTYPE_SETPALETTE:
|
|
||||||
{
|
|
||||||
int index = DC.data.setpalette.index;
|
|
||||||
if (index < 0 || index > 255)
|
|
||||||
{
|
|
||||||
log_add (log_Debug, "DCQ panic: Tried to set palette #%i",
|
|
||||||
index);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
palette[index].r = DC.data.setpalette.r & 0xFF;
|
|
||||||
palette[index].g = DC.data.setpalette.g & 0xFF;
|
|
||||||
palette[index].b = DC.data.setpalette.b & 0xFF;
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case TFB_DRAWCOMMANDTYPE_SETMIPMAP:
|
case TFB_DRAWCOMMANDTYPE_SETMIPMAP:
|
||||||
LockMutex (DC.data.setmipmap.image->mutex);
|
LockMutex (DC.data.setmipmap.image->mutex);
|
||||||
DC.data.setmipmap.image->MipmapImg = DC.data.setmipmap.mipmap;
|
DC.data.setmipmap.image->MipmapImg = DC.data.setmipmap.mipmap;
|
||||||
|
|||||||
@@ -65,20 +65,6 @@ TFB_DrawScreen_Rect (RECT *rect, int r, int g, int b, SCREEN dest)
|
|||||||
TFB_EnqueueDrawCommand (&DC);
|
TFB_EnqueueDrawCommand (&DC);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
|
||||||
TFB_DrawScreen_SetPalette (int paletteIndex, int r, int g, int b)
|
|
||||||
{
|
|
||||||
TFB_DrawCommand DC;
|
|
||||||
|
|
||||||
DC.Type = TFB_DRAWCOMMANDTYPE_SETPALETTE;
|
|
||||||
DC.data.setpalette.r = r;
|
|
||||||
DC.data.setpalette.g = g;
|
|
||||||
DC.data.setpalette.b = b;
|
|
||||||
DC.data.setpalette.index = paletteIndex;
|
|
||||||
|
|
||||||
TFB_EnqueueDrawCommand (&DC);
|
|
||||||
}
|
|
||||||
|
|
||||||
void
|
void
|
||||||
TFB_DrawScreen_Image (TFB_Image *img, int x, int y, int scale,
|
TFB_DrawScreen_Image (TFB_Image *img, int x, int y, int scale,
|
||||||
TFB_ColorMap *cmap, SCREEN dest)
|
TFB_ColorMap *cmap, SCREEN dest)
|
||||||
|
|||||||
@@ -99,7 +99,6 @@ void TFB_DrawScreen_DeleteImage (TFB_Image *img);
|
|||||||
void TFB_DrawScreen_DeleteData (void *);
|
void TFB_DrawScreen_DeleteData (void *);
|
||||||
void TFB_DrawScreen_WaitForSignal (void);
|
void TFB_DrawScreen_WaitForSignal (void);
|
||||||
void TFB_DrawScreen_ReinitVideo (int driver, int flags, int width, int height);
|
void TFB_DrawScreen_ReinitVideo (int driver, int flags, int width, int height);
|
||||||
void TFB_DrawScreen_SetPalette (int paletteIndex, int r, int g, int b);
|
|
||||||
void TFB_DrawScreen_Callback (void (*callback) (void *arg), void *arg);
|
void TFB_DrawScreen_Callback (void (*callback) (void *arg), void *arg);
|
||||||
|
|
||||||
TFB_Image *TFB_DrawImage_New (TFB_Canvas canvas);
|
TFB_Image *TFB_DrawImage_New (TFB_Canvas canvas);
|
||||||
|
|||||||
Reference in New Issue
Block a user