mirror of
https://github.com/ZDoom/raze-gles.git
synced 2025-01-12 03:00:38 +00:00
Add uint32_t PaletteIndexFullbrights[8] so that Polymost can respect the lack of fullbrights in KenBuild and Shadow Warrior.
git-svn-id: https://svn.eduke32.com/eduke32@5210 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
8d78f25bc5
commit
91d6935c88
5 changed files with 10 additions and 2 deletions
|
@ -87,6 +87,8 @@ enum rendmode_t {
|
||||||
#define MAXSPRITESONSCREEN 4096
|
#define MAXSPRITESONSCREEN 4096
|
||||||
#define MAXUNIQHUDID 256 //Extra slots so HUD models can store animation state without messing game sprites
|
#define MAXUNIQHUDID 256 //Extra slots so HUD models can store animation state without messing game sprites
|
||||||
|
|
||||||
|
extern uint32_t PaletteIndexFullbrights[8];
|
||||||
|
|
||||||
#define RESERVEDPALS 4 // don't forget to increment this when adding reserved pals
|
#define RESERVEDPALS 4 // don't forget to increment this when adding reserved pals
|
||||||
#define DETAILPAL (MAXPALOOKUPS - 1)
|
#define DETAILPAL (MAXPALOOKUPS - 1)
|
||||||
#define GLOWPAL (MAXPALOOKUPS - 2)
|
#define GLOWPAL (MAXPALOOKUPS - 2)
|
||||||
|
|
|
@ -849,7 +849,7 @@ void gloadtile_art(int32_t dapic, int32_t dapal, int32_t tintpalnum, int32_t das
|
||||||
if (!fullbrightloadingpass)
|
if (!fullbrightloadingpass)
|
||||||
{
|
{
|
||||||
// regular texture
|
// regular texture
|
||||||
if (dacol > 239 && dacol != 255 && dofullbright)
|
if ((PaletteIndexFullbrights[dacol>>5] & (1<<(dacol&31))) && dofullbright)
|
||||||
hasfullbright = 1;
|
hasfullbright = 1;
|
||||||
|
|
||||||
wpptr->a = 255;
|
wpptr->a = 255;
|
||||||
|
@ -857,7 +857,7 @@ void gloadtile_art(int32_t dapic, int32_t dapal, int32_t tintpalnum, int32_t das
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
// texture with only fullbright areas
|
// texture with only fullbright areas
|
||||||
if (dacol < 240) // regular colors
|
if (!(PaletteIndexFullbrights[dacol>>5] & (1<<(dacol&31)))) // regular colors
|
||||||
{
|
{
|
||||||
wpptr->a = 0;
|
wpptr->a = 0;
|
||||||
hasalpha = 1;
|
hasalpha = 1;
|
||||||
|
|
|
@ -1017,6 +1017,8 @@ void G_DoAutoload(const char *dirname)
|
||||||
|
|
||||||
//////////
|
//////////
|
||||||
|
|
||||||
|
uint32_t PaletteIndexFullbrights[8] = { 0, 0, 0, 0, 0, 0, 0, 2147418112 };
|
||||||
|
|
||||||
static uint8_t water_pal[768], slime_pal[768], title_pal[768], dre_alms[768], ending_pal[768];
|
static uint8_t water_pal[768], slime_pal[768], title_pal[768], dre_alms[768], ending_pal[768];
|
||||||
|
|
||||||
uint8_t *basepaltable[BASEPALCOUNT] = {
|
uint8_t *basepaltable[BASEPALCOUNT] = {
|
||||||
|
|
|
@ -29,6 +29,8 @@ Prepared for public release: 03/28/2005 - Charlie Wiederhold, 3D Realms
|
||||||
#include "pal.h"
|
#include "pal.h"
|
||||||
#include "game.h"
|
#include "game.h"
|
||||||
|
|
||||||
|
uint32_t PaletteIndexFullbrights[8] = { 0, 0, 0, 0, 0, 0, 0, 0 };
|
||||||
|
|
||||||
short f_c = 3;
|
short f_c = 3;
|
||||||
static unsigned char tempbuf[256];
|
static unsigned char tempbuf[256];
|
||||||
unsigned char DefaultPalette[256 * 32];
|
unsigned char DefaultPalette[256 * 32];
|
||||||
|
|
|
@ -30,6 +30,8 @@ uint8_t *basepaltable[1] = {
|
||||||
palette
|
palette
|
||||||
};
|
};
|
||||||
|
|
||||||
|
uint32_t PaletteIndexFullbrights[8] = { 0, 0, 0, 0, 0, 0, 0, 0 };
|
||||||
|
|
||||||
#define NUMPSKYMULTIS 3
|
#define NUMPSKYMULTIS 3
|
||||||
EDUKE32_STATIC_ASSERT(NUMPSKYMULTIS <= MAXPSKYMULTIS);
|
EDUKE32_STATIC_ASSERT(NUMPSKYMULTIS <= MAXPSKYMULTIS);
|
||||||
EDUKE32_STATIC_ASSERT(PSKYOFF_MAX <= MAXPSKYTILES);
|
EDUKE32_STATIC_ASSERT(PSKYOFF_MAX <= MAXPSKYTILES);
|
||||||
|
|
Loading…
Reference in a new issue