From 39a5db515aeaeecf2822ab137664c2c0eb6f85df Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tur=C3=A1nszki=20J=C3=A1nos?= Date: Sun, 29 Jun 2025 06:54:10 +0200 Subject: [PATCH] fixes --- Editor/GraphicsWindow.cpp | 4 ++-- WickedEngine/shaders/volumetricLight_DirectionalPS.hlsl | 2 +- WickedEngine/shaders/volumetricLight_PointPS.hlsl | 2 +- WickedEngine/shaders/volumetricLight_SpotPS.hlsl | 2 +- WickedEngine/shaders/volumetriclight_rectanglePS.hlsl | 2 +- WickedEngine/wiRenderPath2D.cpp | 2 +- WickedEngine/wiRenderPath3D.cpp | 1 - WickedEngine/wiVersion.cpp | 2 +- 8 files changed, 8 insertions(+), 9 deletions(-) diff --git a/Editor/GraphicsWindow.cpp b/Editor/GraphicsWindow.cpp index 88137a260..65c3831c6 100644 --- a/Editor/GraphicsWindow.cpp +++ b/Editor/GraphicsWindow.cpp @@ -1588,12 +1588,12 @@ void GraphicsWindow::Update() if (editor->resolutionScale != editor->renderPath->resolutionScale) { editor->renderPath->resolutionScale = editor->resolutionScale; - editor->ResizeBuffers(); + //editor->ResizeBuffers(); } if (MSAAComboBox.GetItemUserData(MSAAComboBox.GetSelected()) != editor->renderPath->getMSAASampleCount()) { editor->renderPath->setMSAASampleCount((uint32_t)MSAAComboBox.GetItemUserData(MSAAComboBox.GetSelected())); - editor->ResizeBuffers(); + //editor->ResizeBuffers(); } if (IsCollapsed()) diff --git a/WickedEngine/shaders/volumetricLight_DirectionalPS.hlsl b/WickedEngine/shaders/volumetricLight_DirectionalPS.hlsl index b5c4bbed8..60b7bff81 100644 --- a/WickedEngine/shaders/volumetricLight_DirectionalPS.hlsl +++ b/WickedEngine/shaders/volumetricLight_DirectionalPS.hlsl @@ -87,5 +87,5 @@ float4 main(VertexToPixel input) : SV_Target atmosphere_transmittance = GetAtmosphericLightTransmittance(GetWeather().atmosphere, P, L, texture_transmittancelut); } - return max(0, half4(accumulation * light.GetColor().rgb * atmosphere_transmittance, 1)); + return saturateMediump(max(0, half4(accumulation * light.GetColor().rgb * atmosphere_transmittance, 1))); } diff --git a/WickedEngine/shaders/volumetricLight_PointPS.hlsl b/WickedEngine/shaders/volumetricLight_PointPS.hlsl index f57fb0415..77dd4f9b5 100644 --- a/WickedEngine/shaders/volumetricLight_PointPS.hlsl +++ b/WickedEngine/shaders/volumetricLight_PointPS.hlsl @@ -88,5 +88,5 @@ float4 main(VertexToPixel input) : SV_TARGET accumulation *= sampleCount_rcp; - return max(0, half4(accumulation * light.GetColor().rgb, 1)); + return saturateMediump(max(0, half4(accumulation * light.GetColor().rgb, 1))); } diff --git a/WickedEngine/shaders/volumetricLight_SpotPS.hlsl b/WickedEngine/shaders/volumetricLight_SpotPS.hlsl index eb4ff9ce0..99fc93ca5 100644 --- a/WickedEngine/shaders/volumetricLight_SpotPS.hlsl +++ b/WickedEngine/shaders/volumetricLight_SpotPS.hlsl @@ -145,5 +145,5 @@ float4 main(VertexToPixel input) : SV_TARGET accumulation *= sampleCount_rcp; - return max(0, half4(accumulation * light.GetColor().rgb, 1)); + return saturateMediump(max(0, half4(accumulation * light.GetColor().rgb, 1))); } diff --git a/WickedEngine/shaders/volumetriclight_rectanglePS.hlsl b/WickedEngine/shaders/volumetriclight_rectanglePS.hlsl index 7179b7975..132c36f24 100644 --- a/WickedEngine/shaders/volumetriclight_rectanglePS.hlsl +++ b/WickedEngine/shaders/volumetriclight_rectanglePS.hlsl @@ -130,5 +130,5 @@ float4 main(VertexToPixel input) : SV_TARGET accumulation *= sampleCount_rcp; - return max(0, half4(accumulation * light.GetColor().rgb, 1)); + return saturateMediump(max(0, half4(accumulation * light.GetColor().rgb, 1))); } diff --git a/WickedEngine/wiRenderPath2D.cpp b/WickedEngine/wiRenderPath2D.cpp index f18894f63..1f3256943 100644 --- a/WickedEngine/wiRenderPath2D.cpp +++ b/WickedEngine/wiRenderPath2D.cpp @@ -43,7 +43,7 @@ namespace wi desc.height = GetPhysicalHeight(); desc.sample_count = sampleCount; desc.bind_flags = BindFlag::DEPTH_STENCIL; - desc.format = Format::D24_UNORM_S8_UINT; + desc.format = Format::D32_FLOAT_S8X24_UINT; // D24 was erroring on Vulkan AMD though here it would be enough desc.layout = ResourceState::DEPTHSTENCIL; device->CreateTexture(&desc, nullptr, &stencilScaled); device->SetName(&stencilScaled, "stencilScaled"); diff --git a/WickedEngine/wiRenderPath3D.cpp b/WickedEngine/wiRenderPath3D.cpp index 2f6e873f5..2315154f5 100644 --- a/WickedEngine/wiRenderPath3D.cpp +++ b/WickedEngine/wiRenderPath3D.cpp @@ -191,7 +191,6 @@ namespace wi device->Barrier(GPUBarrier::Image(&rtSceneCopy, rtSceneCopy.desc.layout, ResourceState::UNORDERED_ACCESS), cmd); device->ClearUAV(&rtSceneCopy, 0, cmd); device->Barrier(GPUBarrier::Image(&rtSceneCopy, ResourceState::UNORDERED_ACCESS, rtSceneCopy.desc.layout), cmd); - device->SubmitCommandLists(); } { TextureDesc desc; diff --git a/WickedEngine/wiVersion.cpp b/WickedEngine/wiVersion.cpp index 20a249dbe..f8e69b344 100644 --- a/WickedEngine/wiVersion.cpp +++ b/WickedEngine/wiVersion.cpp @@ -9,7 +9,7 @@ namespace wi::version // minor features, major updates, breaking compatibility changes const int minor = 71; // minor bug fixes, alterations, refactors, updates - const int revision = 801; + const int revision = 802; const std::string version_string = std::to_string(major) + "." + std::to_string(minor) + "." + std::to_string(revision);