postfx: eliminat l'uniform oversample i vestigis de supersampling/Lanczos mai implementats
This commit is contained in:
1 parent
c9e6261cf1
commit
984cc820c0
5 files changed
+2006
-2063
No files matched your search
@@ -31,8 +31,8 @@ struct PostFXUniforms {
|
||||
float bleeding;
|
||||
float pixel_scale;
|
||||
float time;
|
||||
float oversample;
|
||||
float flicker;
|
||||
float pad2;
|
||||
// vec4 #3 — paràmetres de scanlines (exposats per preset YAML)
|
||||
float scan_dark_ratio;
|
||||
float scan_dark_floor;
|
||||
@@ -82,7 +82,7 @@ fragment float4 postfx_fs(PostVOut in [[stage_in]],
|
||||
float3 colour;
|
||||
if (u.bleeding > 0.0f) {
|
||||
float tw = float(scene.get_width());
|
||||
float step = u.oversample / tw;
|
||||
float step = 1.0f / tw;
|
||||
float3 ycc = rgb_to_ycc(base);
|
||||
float3 ycc_l2 = rgb_to_ycc(scene.sample(samp, uv - float2(2.0f*step, 0.0f)).rgb);
|
||||
float3 ycc_l1 = rgb_to_ycc(scene.sample(samp, uv - float2(1.0f*step, 0.0f)).rgb);
|
||||
|
||||
@@ -37,7 +37,7 @@ namespace Rendering {
|
||||
// i un fragment shader diferents. Comparteix el mateix vertex shader de
|
||||
// fullscreen-triangle (es carrega de nou internament; els shaders es
|
||||
// destrueixen en acabar la creació del pipeline, i la pipeline en manté la
|
||||
// referència). Renderitza directament al swapchain, sense SS ni Lanczos.
|
||||
// referència). Renderitza directament al swapchain.
|
||||
class CrtPiPipeline {
|
||||
public:
|
||||
CrtPiPipeline() = default;
|
||||
|
||||
@@ -26,8 +26,8 @@ struct PostFXUniforms {
|
||||
// vec4 #2
|
||||
float pixel_scale;
|
||||
float time;
|
||||
float oversample;
|
||||
float flicker;
|
||||
float pad2;
|
||||
// vec4 #3 — paràmetres de scanlines exposats al preset YAML
|
||||
float scan_dark_ratio;
|
||||
float scan_dark_floor;
|
||||
@@ -39,8 +39,7 @@ namespace Rendering {
|
||||
|
||||
// Backend GPU basat en SDL3 GPU API (Vulkan/SPIR-V a Linux i Windows,
|
||||
// Metal/MSL a macOS). Pipeline únic: CPU framebuffer → transfer buffer →
|
||||
// scene texture → PostFX pass → swapchain. Sense supersampling, sense
|
||||
// CrtPi i sense Lanczos (reservats per a fases següents).
|
||||
// scene texture → PostFX pass → swapchain.
|
||||
//
|
||||
// Marcat `final` perquè el destructor crida cleanup() (que és virtual);
|
||||
// sense final, clang-tidy avisa de dispatch virtual durant destrucció.
|
||||
@@ -102,8 +101,8 @@ namespace Rendering {
|
||||
.bleeding = 0.0F,
|
||||
.pixel_scale = 1.0F,
|
||||
.time = 0.0F,
|
||||
.oversample = 1.0F,
|
||||
.flicker = 0.0F,
|
||||
.pad2 = 0.0F,
|
||||
// Defaults canònics: 2/3 brillant + 1/3 fosca, brillantor 42%, suavitzat complet (1 px físic).
|
||||
.scan_dark_ratio = 0.333F,
|
||||
.scan_dark_floor = 0.42F,
|
||||
|
||||
File diff suppressed because it is too large.
Load diff
Reference in new issue
Block a user