From 4ab9391fbb35e627f2033494f0440536bb3341a8 Mon Sep 17 00:00:00 2001 From: Jason Ekstrand Date: Mon, 30 Nov 2015 14:19:41 -0800 Subject: vk/0.210.0: Rework dynamic states --- src/vulkan/anv_pipeline.c | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) (limited to 'src/vulkan/anv_pipeline.c') diff --git a/src/vulkan/anv_pipeline.c b/src/vulkan/anv_pipeline.c index 16d0546..e4209bd 100644 --- a/src/vulkan/anv_pipeline.c +++ b/src/vulkan/anv_pipeline.c @@ -849,16 +849,17 @@ anv_pipeline_init_dynamic_state(struct anv_pipeline *pipeline, if (states & (1 << VK_DYNAMIC_STATE_DEPTH_BIAS)) { assert(pCreateInfo->pRasterState); - dynamic->depth_bias.bias = pCreateInfo->pRasterState->depthBias; + dynamic->depth_bias.bias = + pCreateInfo->pRasterState->depthBiasConstantFactor; dynamic->depth_bias.clamp = pCreateInfo->pRasterState->depthBiasClamp; - dynamic->depth_bias.slope_scaled = - pCreateInfo->pRasterState->slopeScaledDepthBias; + dynamic->depth_bias.slope = + pCreateInfo->pRasterState->depthBiasSlopeFactor; } if (states & (1 << VK_DYNAMIC_STATE_BLEND_CONSTANTS)) { assert(pCreateInfo->pColorBlendState); typed_memcpy(dynamic->blend_constants, - pCreateInfo->pColorBlendState->blendConst, 4); + pCreateInfo->pColorBlendState->blendConstants, 4); } /* If there is no depthstencil attachment, then don't read @@ -884,25 +885,25 @@ anv_pipeline_init_dynamic_state(struct anv_pipeline *pipeline, if (states & (1 << VK_DYNAMIC_STATE_STENCIL_COMPARE_MASK)) { assert(pCreateInfo->pDepthStencilState); dynamic->stencil_compare_mask.front = - pCreateInfo->pDepthStencilState->front.stencilCompareMask; + pCreateInfo->pDepthStencilState->front.compareMask; dynamic->stencil_compare_mask.back = - pCreateInfo->pDepthStencilState->back.stencilCompareMask; + pCreateInfo->pDepthStencilState->back.compareMask; } if (states & (1 << VK_DYNAMIC_STATE_STENCIL_WRITE_MASK)) { assert(pCreateInfo->pDepthStencilState); dynamic->stencil_write_mask.front = - pCreateInfo->pDepthStencilState->front.stencilWriteMask; + pCreateInfo->pDepthStencilState->front.writeMask; dynamic->stencil_write_mask.back = - pCreateInfo->pDepthStencilState->back.stencilWriteMask; + pCreateInfo->pDepthStencilState->back.writeMask; } if (states & (1 << VK_DYNAMIC_STATE_STENCIL_REFERENCE)) { assert(pCreateInfo->pDepthStencilState); dynamic->stencil_reference.front = - pCreateInfo->pDepthStencilState->front.stencilReference; + pCreateInfo->pDepthStencilState->front.reference; dynamic->stencil_reference.back = - pCreateInfo->pDepthStencilState->back.stencilReference; + pCreateInfo->pDepthStencilState->back.reference; } } -- cgit v1.1