Skip to content

Commit

Permalink
Fix build, add missing changes
Browse files Browse the repository at this point in the history
  • Loading branch information
pvictress committed Dec 6, 2024
1 parent 7ec582a commit 0ae7d90
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 13 deletions.
13 changes: 1 addition & 12 deletions src/i_truecolor.c
Original file line number Diff line number Diff line change
Expand Up @@ -29,21 +29,10 @@



typedef union
{
uint32_t i;
struct {
uint8_t b;
uint8_t g;
uint8_t r;
uint8_t a;
};
} tcpixel_t;

// [JN] Double pointer used for additive blending.
// It does not store actual color data but serves as a shortcut
// to avoid using MIN during rendering.
static uint8_t **additive_lut = NULL;
uint8_t **additive_lut = NULL;

void I_InitTCTransMaps (void)
{
Expand Down
16 changes: 15 additions & 1 deletion src/i_truecolor.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,19 @@
#include <stdint.h>


typedef union
{
uint32_t i;
struct {
uint8_t b;
uint8_t g;
uint8_t r;
uint8_t a;
};
} tcpixel_t;

extern uint8_t **additive_lut;

extern void I_InitTCTransMaps (void);

extern const int I_ShadeFactor[];
Expand All @@ -39,7 +52,8 @@ extern const double colorblind_matrix[][3][3];

// Doom:
#define TRANMAP_ALPHA 0xA8 // 168 (66% opacity)
#define FUZZMAP_ALPHA 0x40 // 64 (25% opacity)
#define FUZZ_ALPHA 0xD3 // 211 (17% darkening)
#define FUZZTL_ALPHA 0x40 // 64 (25% opacity)

// Heretic and Hexen:
#define TINTTAB_ALPHA 0x60 // 96 (38% opacity)
Expand Down

0 comments on commit 0ae7d90

Please sign in to comment.