diff --git a/samples/ComputeSharp.SwapChain.Shaders.Shared/ContouredLayers.cs b/samples/ComputeSharp.SwapChain.Shaders.Shared/ContouredLayers.cs index 04b6f7ab..aaa46d77 100644 --- a/samples/ComputeSharp.SwapChain.Shaders.Shared/ContouredLayers.cs +++ b/samples/ComputeSharp.SwapChain.Shaders.Shared/ContouredLayers.cs @@ -117,7 +117,7 @@ internal readonly partial struct ContouredLayers : IPixelShader float3 col; - col = (float3)1.0 * (1.0f - (0.75f / (1.0f + (sh * sh * 2.0f)))); + col = (float3)1.0f * (1.0f - (0.75f / (1.0f + (sh * sh * 2.0f)))); col = Hlsl.Min(col * tx * 3.0f, 1.0f); return col; diff --git a/tests/ComputeSharp.Tests/Shaders/Compute/ContouredLayers.cs b/tests/ComputeSharp.Tests/Shaders/Compute/ContouredLayers.cs index 230fc637..b47e909d 100644 --- a/tests/ComputeSharp.Tests/Shaders/Compute/ContouredLayers.cs +++ b/tests/ComputeSharp.Tests/Shaders/Compute/ContouredLayers.cs @@ -121,7 +121,7 @@ internal readonly partial struct ContouredLayers : IComputeShader float3 col; - col = (float3)1.0 * (1.0f - 0.75f / (1.0f + sh * sh * 2.0f)); + col = (float3)1.0f * (1.0f - 0.75f / (1.0f + sh * sh * 2.0f)); col = Hlsl.Min(col * tx * 3.0f, 1.0f); return col; diff --git a/tests/ComputeSharp.Tests/ShadersTests.cs b/tests/ComputeSharp.Tests/ShadersTests.cs index 3b0b2b39..e307723e 100644 --- a/tests/ComputeSharp.Tests/ShadersTests.cs +++ b/tests/ComputeSharp.Tests/ShadersTests.cs @@ -178,6 +178,10 @@ public class ShadersTests static void RunPixelShader(ReadWriteTexture2D texture) where T : struct, IPixelShader { + ShaderInfo info = ReflectionServices.GetShaderInfo(); + + Assert.IsFalse(info.RequiresDoublePrecisionSupport); + texture.GraphicsDevice.ForEach(texture, (T)Activator.CreateInstance(typeof(T), 0f)!); }