From 6e124be1ce722a231b296ba9cd6e234c6946475d Mon Sep 17 00:00:00 2001 From: Sergio Pedri Date: Sat, 30 Oct 2021 14:58:36 +0200 Subject: [PATCH] Minor code style tweaks --- samples/ComputeSharp.SwapChain/Shaders/HelloWorld.cs | 8 ++++---- tests/ComputeSharp.Tests/Shaders/Compute/HelloWorld.cs | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/samples/ComputeSharp.SwapChain/Shaders/HelloWorld.cs b/samples/ComputeSharp.SwapChain/Shaders/HelloWorld.cs index 1a38675b..8e60a9ff 100644 --- a/samples/ComputeSharp.SwapChain/Shaders/HelloWorld.cs +++ b/samples/ComputeSharp.SwapChain/Shaders/HelloWorld.cs @@ -5,7 +5,7 @@ /// Ported from . /// [AutoConstructor] - internal readonly partial struct HelloWorld : IPixelShader + internal readonly partial struct HelloWorld : IPixelShader { /// /// The current time since the start of the application. @@ -13,13 +13,13 @@ public readonly float time; /// - public Float4 Execute() + public float4 Execute() { // Normalized screen space UV coordinates from 0.0 to 1.0 - Float2 uv = ThreadIds.Normalized.XY; + float2 uv = ThreadIds.Normalized.XY; // Time varying pixel color - Float3 col = 0.5f + 0.5f * Hlsl.Cos(time + new Float3(uv, uv.X) + new Float3(0, 2, 4)); + float3 col = 0.5f + 0.5f * Hlsl.Cos(time + new float3(uv, uv.X) + new float3(0, 2, 4)); // Output to screen return new(col, 1f); diff --git a/tests/ComputeSharp.Tests/Shaders/Compute/HelloWorld.cs b/tests/ComputeSharp.Tests/Shaders/Compute/HelloWorld.cs index f12adcdb..aab1ab01 100644 --- a/tests/ComputeSharp.Tests/Shaders/Compute/HelloWorld.cs +++ b/tests/ComputeSharp.Tests/Shaders/Compute/HelloWorld.cs @@ -5,7 +5,7 @@ /// Ported from . /// [AutoConstructor] - internal readonly partial struct HelloWorld : IPixelShader + internal readonly partial struct HelloWorld : IPixelShader { /// /// The current time since the start of the application. @@ -13,13 +13,13 @@ public readonly float time; /// - public Float4 Execute() + public float4 Execute() { // Normalized screen space UV coordinates from 0.0 to 1.0 - Float2 uv = ThreadIds.Normalized.XY; + float2 uv = ThreadIds.Normalized.XY; // Time varying pixel color - Float3 col = 0.5f + 0.5f * Hlsl.Cos(time + new Float3(uv, uv.X) + new Float3(0, 2, 4)); + float3 col = 0.5f + 0.5f * Hlsl.Cos(time + new float3(uv, uv.X) + new float3(0, 2, 4)); // Output to screen return new(col, 1f);