diff --git a/src/ComputeSharp.D2D1/Shaders/Interop/D2D1ShaderCompiler.cs b/src/ComputeSharp.D2D1/Shaders/Interop/D2D1ShaderCompiler.cs
index c1450498..c52b142a 100644
--- a/src/ComputeSharp.D2D1/Shaders/Interop/D2D1ShaderCompiler.cs
+++ b/src/ComputeSharp.D2D1/Shaders/Interop/D2D1ShaderCompiler.cs
@@ -19,22 +19,22 @@ public static class D2D1ShaderCompiler
///
/// Compiles a new HLSL shader from the input source code.
///
- /// The HLSL source code to compile.
+ /// The HLSL source code to compile.
/// The entry point of the shader being compiled.
/// The shader profile to use to compile the shader.
/// The compiler options to use to compile the shader.
/// The bytecode for the compiled shader.
/// Thrown if the compilation fails.
public static ReadOnlyMemory Compile(
- ReadOnlySpan source,
+ ReadOnlySpan hlslSource,
ReadOnlySpan entryPoint,
D2D1ShaderProfile shaderProfile,
D2D1ShaderCompilerOptions options)
{
// Encode the HLSL source to ASCII
- int maxSourceLength = Encoding.ASCII.GetMaxByteCount(source.Length);
+ int maxSourceLength = Encoding.ASCII.GetMaxByteCount(hlslSource.Length);
byte[] sourceBuffer = ArrayPool.Shared.Rent(maxSourceLength);
- int sourceWrittenBytes = Encoding.ASCII.GetBytes(source, sourceBuffer);
+ int sourceWrittenBytes = Encoding.ASCII.GetBytes(hlslSource, sourceBuffer);
// Encode the entry point to ASCII
int maxEntryPointLength = Encoding.ASCII.GetMaxByteCount(entryPoint.Length);
@@ -50,15 +50,15 @@ public static class D2D1ShaderCompiler
///
/// Compiles a new HLSL shader from the input source code.
///
- /// The HLSL source code to compile (in ASCII).
- /// The entry point of the shader being compiled (in ASCII).
+ /// The HLSL source code to compile (in ASCII).
+ /// The entry point of the shader being compiled (in ASCII).
/// The shader profile to use to compile the shader.
/// The compiler options to use to compile the shader.
/// The bytecode for the compiled shader.
/// Thrown if the compilation fails.
public static unsafe ReadOnlyMemory Compile(
- ReadOnlySpan source,
- ReadOnlySpan entryPoint,
+ ReadOnlySpan hlslSourceAscii,
+ ReadOnlySpan entryPointAscii,
D2D1ShaderProfile shaderProfile,
D2D1ShaderCompilerOptions options)
{
@@ -70,10 +70,10 @@ public static class D2D1ShaderCompiler
// Compile the standalone D2D1 full shader
using ComPtr d3DBlobFullShader = D3DCompiler.CompileShader(
- source: source,
+ source: hlslSourceAscii,
macro: D3DCompiler.ASCII.D2D_FULL_SHADER,
- d2DEntry: entryPoint,
- entryPoint: entryPoint,
+ d2DEntry: entryPointAscii,
+ entryPoint: entryPointAscii,
target: D3DCompiler.ASCII.GetPixelShaderProfile(shaderProfile),
flags: (uint)options);
@@ -87,9 +87,9 @@ public static class D2D1ShaderCompiler
// Compile the export function
using ComPtr d3DBlobFunction = D3DCompiler.CompileShader(
- source: source,
+ source: hlslSourceAscii,
macro: D3DCompiler.ASCII.D2D_FUNCTION,
- d2DEntry: entryPoint,
+ d2DEntry: entryPointAscii,
entryPoint: default,
target: D3DCompiler.ASCII.GetLibraryProfile(shaderProfile),
flags: (uint)options);