Improve consistency in interop API parameters ordering

このコミットが含まれているのは:
Sergio Pedri committed 2022-12-22 10:56:03 -08:00
1 親 e64b638454
コミット 7761d0bbd8
10ファイル変更
+22 -22

検索条件に一致するファイルはありません

+1 -1
ファイルの表示
@@ -47,7 +47,7 @@ public partial class D2D1PixelShaderEffectTests
[ExpectedException(typeof(ArgumentNullException), AllowDerivedTypes = false)]
public unsafe void SetConstantBufferForD2D1Effect_NullD2D1Effect()
{
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect<InvertEffect>(default, null);
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect<InvertEffect>(null, default);
}
[TestMethod]
+1 -1
ファイルの表示
@@ -630,6 +630,6 @@ public partial class D2D1PixelShaderTests
[ExpectedException(typeof(ArgumentNullException), AllowDerivedTypes = false)]
public unsafe void SetConstantBufferForD2D1DrawInfo_NullD2D1DrawInfo()
{
D2D1PixelShader.SetConstantBufferForD2D1DrawInfo<InvertEffect>(default, null);
D2D1PixelShader.SetConstantBufferForD2D1DrawInfo<InvertEffect>(null, default);
}
}
+8 -8
ファイルの表示
@@ -198,7 +198,7 @@ public partial class D2D1ResourceTextureManagerTests
D2D1PixelShaderEffect.CreateFromD2D1DeviceContext<IndexFrom2DResourceTextureShader>(d2D1DeviceContext.Get(), (void**)d2D1Effect.GetAddressOf());
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(default(IndexFrom2DResourceTextureShader), d2D1Effect.Get());
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(d2D1Effect.Get(), default(IndexFrom2DResourceTextureShader));
using ComPtr<IUnknown> resourceTextureManager = default;
@@ -257,7 +257,7 @@ public partial class D2D1ResourceTextureManagerTests
D2D1PixelShaderEffect.CreateFromD2D1DeviceContext<IndexFrom2DResourceTextureShader>(d2D1DeviceContext.Get(), (void**)d2D1Effect.GetAddressOf());
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(default(IndexFrom2DResourceTextureShader), d2D1Effect.Get());
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(d2D1Effect.Get(), default(IndexFrom2DResourceTextureShader));
using ComPtr<IUnknown> resourceTextureManager = default;
@@ -321,7 +321,7 @@ public partial class D2D1ResourceTextureManagerTests
D2D1PixelShaderEffect.CreateFromD2D1DeviceContext<IndexFrom2DResourceTextureShader>(d2D1DeviceContext.Get(), (void**)d2D1Effect.GetAddressOf());
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(default(IndexFrom2DResourceTextureShader), d2D1Effect.Get());
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(d2D1Effect.Get(), default(IndexFrom2DResourceTextureShader));
string assemblyPath = Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location)!;
string expectedPath = Path.Combine(assemblyPath, "Assets", "Landscape.png");
@@ -498,7 +498,7 @@ public partial class D2D1ResourceTextureManagerTests
IndexFrom3DResourceTextureShader shader = new(expected.Height / 4);
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(in shader, d2D1Effect.Get());
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(d2D1Effect.Get(), in shader);
using ComPtr<IUnknown> resourceTextureManager = default;
@@ -575,7 +575,7 @@ public partial class D2D1ResourceTextureManagerTests
CopyFromResourceTexture1DShader shader = new(width);
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(in shader, d2D1Effect.Get());
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(d2D1Effect.Get(), in shader);
byte[] texture = new byte[width];
@@ -663,7 +663,7 @@ public partial class D2D1ResourceTextureManagerTests
CopyFromResourceTexture2DShader shader = new(width, height);
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(in shader, d2D1Effect.Get());
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(d2D1Effect.Get(), in shader);
byte[] texture = new byte[width * height];
@@ -766,7 +766,7 @@ public partial class D2D1ResourceTextureManagerTests
CopyFromResourceTexture3DShader shader = new(width, height, depth);
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(in shader, d2D1Effect.Get());
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(d2D1Effect.Get(), in shader);
byte[] texture = new byte[width * height * depth];
@@ -860,7 +860,7 @@ public partial class D2D1ResourceTextureManagerTests
D2D1PixelShaderEffect.CreateFromD2D1DeviceContext<NullResourceTextureShader>(d2D1DeviceContext.Get(), (void**)d2D1Effect.GetAddressOf());
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(default(NullResourceTextureShader), d2D1Effect.Get());
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(d2D1Effect.Get(), default(NullResourceTextureShader));
using ComPtr<ID2D1Bitmap> d2D1BitmapTarget = D2D1Helper.CreateD2D1BitmapAndSetAsTarget(d2D1DeviceContext.Get(), 128, 128);
+1 -1
ファイルの表示
@@ -158,7 +158,7 @@ public partial class D2D1TransformMapperTests
D2D1PixelShaderEffect.CreateFromD2D1DeviceContext<ShaderWithDispatchArea>(d2D1DeviceContext.Get(), (void**)d2D1Effect.GetAddressOf());
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(new ShaderWithDispatchArea(111, 222), d2D1Effect.Get());
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(d2D1Effect.Get(), new ShaderWithDispatchArea(111, 222));
DispatchAreaTransformMapper transformMapper = new() { ExpectedWidth = 111, ExpectedHeight = 222 };
+3 -3
ファイルの表示
@@ -425,9 +425,9 @@ public sealed partial class BokehBlurEffect
// Set the constant buffers
for (int i = 0; i < numberOfComponents; i++)
{
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(new VerticalConvolution.Shader((int)kernelSize), verticalConvolutionEffectsForReals[i].Get());
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(new VerticalConvolution.Shader((int)kernelSize), verticalConvolutionEffectsForImaginaries[i].Get());
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(new HorizontalConvolutionAndAccumulatePartials.Shader((int)kernelSize, this.kernelParameters[i].Z, this.kernelParameters[i].W), horizontalConvolutionEffects[i].Get());
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(verticalConvolutionEffectsForReals[i].Get(), new VerticalConvolution.Shader((int)kernelSize));
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(verticalConvolutionEffectsForImaginaries[i].Get(), new VerticalConvolution.Shader((int)kernelSize));
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(horizontalConvolutionEffects[i].Get(), new HorizontalConvolutionAndAccumulatePartials.Shader((int)kernelSize, this.kernelParameters[i].Z, this.kernelParameters[i].W));
}
// Build the effect graph:
+2 -2
ファイルの表示
@@ -124,7 +124,7 @@ internal static class D2D1TestRunner
D2D1PixelShaderEffect.CreateFromD2D1DeviceContext<T>(d2D1DeviceContext.Get(), (void**)d2D1Effect.GetAddressOf());
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(in shader, d2D1Effect.Get());
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(d2D1Effect.Get(), in shader);
if (transformMapper is not null)
{
@@ -173,7 +173,7 @@ internal static class D2D1TestRunner
D2D1PixelShaderEffect.CreateFromD2D1DeviceContext<T>(d2D1DeviceContext.Get(), (void**)d2D1Effect.GetAddressOf());
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(in shader, d2D1Effect.Get());
D2D1PixelShaderEffect.SetConstantBufferForD2D1Effect(d2D1Effect.Get(), in shader);
if (transformMapper is not null)
{