MGA: Implement gamma correction for 24+ bpp modes

This commit is contained in:
Cacodemon345
2023-12-24 01:46:10 +06:00
parent 708a700abd
commit 70d6d5954b
4 changed files with 55 additions and 33 deletions

View File

@@ -268,6 +268,9 @@ typedef struct svga_t {
/* Pointer to monitor */
monitor_t *monitor;
/* Enable LUT mapping of >= 24 bpp modes. */
int lut_map;
void * dev8514;
void * xga;
} svga_t;

View File

@@ -32,6 +32,9 @@ using atomic_int = std::atomic_int;
#define makecol(r, g, b) ((b) | ((g) << 8) | ((r) << 16))
#define makecol32(r, g, b) ((b) | ((g) << 8) | ((r) << 16))
#define getcolr(color) (((color) >> 16) & 0xFF)
#define getcolg(color) (((color) >> 8) & 0xFF)
#define getcolb(color) ((color) & 0xFF)
enum {
VID_NONE = 0,