From f3c124285831aa06af282968ff402ee2d05b9de4 Mon Sep 17 00:00:00 2001 From: fgsfds Date: Mon, 13 May 2024 12:15:42 +0200 Subject: [PATCH 1/2] port: more detail texture adjustment --- port/fast3d/gfx_pc.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/port/fast3d/gfx_pc.cpp b/port/fast3d/gfx_pc.cpp index e5722d8c8..fe989e085 100644 --- a/port/fast3d/gfx_pc.cpp +++ b/port/fast3d/gfx_pc.cpp @@ -1540,7 +1540,7 @@ static void gfx_sp_tri1(uint8_t vtx1_idx, uint8_t vtx2_idx, uint8_t vtx3_idx, bo // HACK: very roughly eyeballed based on the carpets in Defection // this is actually supposed to be calculated per pixel const float distance_frac = std::max(0.f, std::min(w / 1024.f, 1.f)); - tmp.r = tmp.g = tmp.b = tmp.a = (0.65f + distance_frac * 0.35f) * 255.f; + tmp.r = tmp.g = tmp.b = tmp.a = (0.7f + distance_frac * 0.3f) * 255.f; } else { tmp.r = tmp.g = tmp.b = tmp.a = 255; } From c5c1ef1d4e4cacd2c31c245372e2a1f701d19af9 Mon Sep 17 00:00:00 2001 From: fgsfds Date: Mon, 13 May 2024 12:19:34 +0200 Subject: [PATCH 2/2] port: ask for high performance GPU on windows --- port/src/system.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/port/src/system.c b/port/src/system.c index e889f75df..36f9475ce 100644 --- a/port/src/system.c +++ b/port/src/system.c @@ -22,6 +22,10 @@ static CREATEWAITABLETIMEREXAFN pfnCreateWaitableTimerExA; // winapi also provides a yield macro #define DO_YIELD() YieldProcessor() +// ask system for high performance GPU, if any +__attribute__((dllexport)) u32 NvOptimusEnablement = 1; +__attribute__((dllexport)) u32 AmdPowerXpressRequestHighPerformance = 1; + #else #ifndef _GNU_SOURCE