clear is here, draw is not

This commit is contained in:
2025-12-23 19:08:38 +02:00
parent 3b4e2eea32
commit fb5e607f88
8 changed files with 93 additions and 38 deletions

View File

@@ -1,5 +1,5 @@
#include "../vulkan_state.h"
#include "../raster_libraries.h"
#include "../libraries.h"
#include "tier1/utlbuffer.h"
#include "tier1/utlvector.h"
#include "tier2/ifilesystem.h"
@@ -221,13 +221,6 @@ BEGIN_BUILD_PIPELINE_LIBRARY(PixelShader)
pipeline.pStages = &shader;
depthStencil.sType = VK_STRUCTURE_TYPE_PIPELINE_DEPTH_STENCIL_STATE_CREATE_INFO;
depthStencil.minDepthBounds = 0;
depthStencil.maxDepthBounds = 1;
depthStencil.depthTestEnable = VK_TRUE;
depthStencil.depthWriteEnable = VK_TRUE;
depthStencil.depthBoundsTestEnable = VK_FALSE;
depthStencil.stencilTestEnable = VK_FALSE;
depthStencil.depthCompareOp = VK_COMPARE_OP_LESS;
pipeline.pDepthStencilState = &depthStencil;
skipshader:
@@ -258,25 +251,12 @@ BEGIN_BUILD_PIPELINE_LIBRARY(PixelOutput)
render.depthAttachmentFormat = VK_FORMAT_D32_SFLOAT;;
depthStencil.sType = VK_STRUCTURE_TYPE_PIPELINE_DEPTH_STENCIL_STATE_CREATE_INFO;
depthStencil.minDepthBounds = 0;
depthStencil.maxDepthBounds = 1;
depthStencil.depthTestEnable = VK_TRUE;
depthStencil.depthWriteEnable = VK_TRUE;
depthStencil.depthBoundsTestEnable = VK_FALSE;
depthStencil.stencilTestEnable = VK_FALSE;
depthStencil.depthCompareOp = VK_COMPARE_OP_LESS;
for ( auto e: m_eFormats )
{
VkPipelineColorBlendAttachmentState a = {};
a.blendEnable = VK_TRUE;
a.blendEnable = VK_TRUE;
a.srcColorBlendFactor = VK_BLEND_FACTOR_SRC_ALPHA;
a.dstColorBlendFactor = VK_BLEND_FACTOR_ONE_MINUS_SRC_ALPHA;
a.colorBlendOp = VK_BLEND_OP_ADD;
a.srcAlphaBlendFactor = VK_BLEND_FACTOR_ONE;
a.dstAlphaBlendFactor = VK_BLEND_FACTOR_ZERO;
a.alphaBlendOp = VK_BLEND_OP_ADD;
a.colorWriteMask = VK_COLOR_COMPONENT_R_BIT | VK_COLOR_COMPONENT_G_BIT | VK_COLOR_COMPONENT_B_BIT | VK_COLOR_COMPONENT_A_BIT;
a.blendEnable = VK_FALSE;
attachments.AppendTail(a);
}
blend.sType = VK_STRUCTURE_TYPE_PIPELINE_COLOR_BLEND_STATE_CREATE_INFO;