From 61ec63b71f9fc3163ef5a8d985fbb53e3f02dbf9 Mon Sep 17 00:00:00 2001 From: cosmonaut Date: Fri, 25 Feb 2022 17:49:40 -0800 Subject: [PATCH] Blend state ABI break --- src/Refresh.cs | 23 +++++++++++------------ 1 file changed, 11 insertions(+), 12 deletions(-) diff --git a/src/Refresh.cs b/src/Refresh.cs index e4cb80d..e4991af 100644 --- a/src/Refresh.cs +++ b/src/Refresh.cs @@ -437,7 +437,7 @@ namespace RefreshCS } [StructLayout(LayoutKind.Sequential)] - public struct ColorTargetBlendState + public struct ColorAttachmentBlendState { public byte blendEnable; public BlendFactor sourceColorBlendFactor; @@ -492,6 +492,13 @@ namespace RefreshCS public ulong uniformBufferSize; } + [StructLayout(LayoutKind.Sequential)] + public struct ComputePipelineCreateInfo + { + public ShaderStageState computeShaderState; + public ComputePipelineLayoutCreateInfo pipelineLayoutCreateInfo; + } + [StructLayout(LayoutKind.Sequential)] public struct ViewportState { @@ -537,27 +544,19 @@ namespace RefreshCS } [StructLayout(LayoutKind.Sequential)] - public unsafe struct ColorBlendState + public unsafe struct PipelineColorBlendState { public byte logicOpEnable; public LogicOp logicOp; - public IntPtr blendStates; - public uint blendStateCount; public fixed float blendConstants[4]; } - [StructLayout(LayoutKind.Sequential)] - public struct ComputePipelineCreateInfo - { - public ShaderStageState computeShaderState; - public ComputePipelineLayoutCreateInfo pipelineLayoutCreateInfo; - } - [StructLayout(LayoutKind.Sequential)] public struct ColorAttachmentDescription { public TextureFormat format; public SampleCount sampleCount; + public ColorAttachmentBlendState blendState; } [StructLayout(LayoutKind.Sequential)] @@ -580,7 +579,7 @@ namespace RefreshCS public RasterizerState rasterizerState; public MultisampleState multisampleState; public DepthStencilState depthStencilState; - public ColorBlendState colorBlendState; + public PipelineColorBlendState colorBlendState; public GraphicsPipelineLayoutCreateInfo pipelineLayoutCreateInfo; public GraphicsPipelineAttachmentInfo attachmentInfo; }