Rename PIELIGHT.argb to PIELIGHT.rgba so that it reflects its actual format.

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@4509 4a71c877-e1ca-e34f-864e-861f7616d084
master
Freddie Witherden 2008-04-05 22:33:22 +00:00
parent 5bcc0ed6df
commit 6459f52cf2
7 changed files with 20 additions and 20 deletions

View File

@ -84,7 +84,7 @@ typedef struct { UBYTE r, g, b, a; } PIELIGHTBYTES;
/** Our basic colour type. Use whenever you want to define a colour.
* Set bytes separetely, and do not assume a byte order between the components. */
typedef union { PIELIGHTBYTES byte; UDWORD argb; UBYTE vector[4]; } PIELIGHT;
typedef union { PIELIGHTBYTES byte; UDWORD rgba; UBYTE vector[4]; } PIELIGHT;
typedef struct
{

View File

@ -30,7 +30,7 @@ void pie_SetDefaultStates(void)//Sets all states
rendStates.fogEnabled = false;// enable fog before renderer
rendStates.fog = false;//to force reset to false
pie_SetFogStatus(false);
black.argb = 0;
black.rgba = 0;
black.byte.a = 255;
pie_SetFogColour(black);//nicks colour
@ -74,7 +74,7 @@ void pie_EnableFog(BOOL val)
{
PIELIGHT black;
black.argb = 0;
black.rgba = 0;
black.byte.a = 255;
pie_SetFogColour(black); // clear background to black
}

View File

@ -4608,9 +4608,9 @@ static void addConstructionLine(DROID *psDroid, STRUCTURE *psStructure)
colour.byte.r = 0;
colour.byte.g = 0;
}
pts[0].light.argb = 0xff000000;
pts[1].light.argb = 0xff000000;
pts[2].light.argb = 0xff000000;
pts[0].light.rgba = 0xff000000;
pts[1].light.rgba = 0xff000000;
pts[2].light.rgba = 0xff000000;
pts[0].u = 0;
pts[0].v = 0;

View File

@ -2467,7 +2467,7 @@ BOOL loadGame(const char *pGameToLoad, BOOL keepObjects, BOOL freeMem, BOOL User
fogStatus = saveGameData.fogState;
fogStatus &= FOG_FLAGS;
}
colour.argb = saveGameData.fogColour;
colour.rgba = saveGameData.fogColour;
pie_SetFogColour(colour);
}
if (saveGameVersion >= VERSION_19)//V21
@ -4599,7 +4599,7 @@ bool gameLoadV(PHYSFS_file* fileHandle, unsigned int version)
fogStatus = saveGameData.fogState;
fogStatus &= FOG_FLAGS;
}
colour.argb = saveGameData.fogColour;
colour.rgba = saveGameData.fogColour;
pie_SetFogColour(colour);
}
@ -4923,7 +4923,7 @@ static bool writeGameFile(const char* fileName, SDWORD saveType)
saveGame.offWorldKeepLists = offWorldKeepLists;
saveGame.RubbleTile = getRubbleTileNum();
saveGame.WaterTile = getWaterTileNum();
saveGame.fogColour = pie_GetFogColour().argb;
saveGame.fogColour = pie_GetFogColour().rgba;
saveGame.fogState = fogStatus;
if(pie_GetFogEnabled())
{

View File

@ -155,7 +155,7 @@ GAMECODE gameLoop(void)
// set the fog color to black (RGB)
// the fogbox will get this color
black.argb = 0;
black.rgba = 0;
black.byte.a = 255;
pie_SetFogColour(black);
}

View File

@ -352,7 +352,7 @@ static void ClearRadar(UDWORD *screen)
{
for (j = 0; j < RadarHeight; j++)
{
*pScr++ = WZCOL_RADAR_BACKGROUND.argb;
*pScr++ = WZCOL_RADAR_BACKGROUND.rgba;
}
}
}
@ -441,9 +441,9 @@ static void DrawRadarTiles(UDWORD *screen,UDWORD Modulus,UWORD boxSizeH,UWORD bo
{
if (!getRevealStatus() || TEST_TILE_VISIBLE(selectedPlayer, WTile) || godMode)
{
*WScr = appliedRadarColour(radarDrawMode, WTile).argb;
*WScr = appliedRadarColour(radarDrawMode, WTile).rgba;
} else {
*WScr = WZCOL_RADAR_BACKGROUND.argb;
*WScr = WZCOL_RADAR_BACKGROUND.rgba;
}
/* Next pixel, next tile */
WScr++;
@ -471,7 +471,7 @@ static void DrawRadarTiles(UDWORD *screen,UDWORD Modulus,UWORD boxSizeH,UWORD bo
col.byte.r = sqrtf(col.byte.r * WTile->illumination);
col.byte.b = sqrtf(col.byte.b * WTile->illumination);
col.byte.g = sqrtf(col.byte.g * WTile->illumination);
Val = col.argb;
Val = col.rgba;
for(c=0; c<SizeV; c++)
{
@ -479,7 +479,7 @@ static void DrawRadarTiles(UDWORD *screen,UDWORD Modulus,UWORD boxSizeH,UWORD bo
for(d=0; d<SizeH; d++)
{
*WPtr = appliedRadarColour(radarDrawMode, WTile).argb;
*WPtr = appliedRadarColour(radarDrawMode, WTile).rgba;
WPtr++;
}
Ptr += Modulus;
@ -496,7 +496,7 @@ static void DrawRadarTiles(UDWORD *screen,UDWORD Modulus,UWORD boxSizeH,UWORD bo
for(d=0; d<SizeH; d++)
{
*WPtr = WZCOL_RADAR_BACKGROUND.argb;
*WPtr = WZCOL_RADAR_BACKGROUND.rgba;
WPtr++;
}
Ptr += Modulus;
@ -597,7 +597,7 @@ static void DrawRadarObjects(UDWORD *screen,UDWORD Modulus,UWORD boxSizeH,UWORD
WPtr = Ptr;
for(d=0; d<SizeH; d++)
{
*WPtr = col.argb;
*WPtr = col.rgba;
WPtr++;
}
Ptr += Modulus;
@ -696,7 +696,7 @@ static void DrawRadarObjects(UDWORD *screen,UDWORD Modulus,UWORD boxSizeH,UWORD
WPtr = Ptr;
for(d=0; d<SSizeH; d++)
{
*WPtr = col.argb;
*WPtr = col.rgba;
WPtr++;
}
Ptr += Modulus;
@ -849,7 +849,7 @@ static void drawViewingWindow( UDWORD x, UDWORD y, UDWORD boxSizeH, UDWORD boxSi
colour.byte.b = 0x3f;
default:
// black
colour.argb = 0;
colour.rgba = 0;
colour.byte.a = 0x3f;
break;

View File

@ -159,7 +159,7 @@ void war_SetFog(BOOL val)
PIELIGHT black;
setRevealStatus(true);
black.argb = 0;
black.rgba = 0;
black.byte.a = 255;
pie_SetFogColour(black);
}