1
0
mirror of https://github.com/doitsujin/dxvk.git synced 2025-03-15 07:29:17 +01:00

[dxvk] Don't redundantly reset spec constant values

No longer needed.
This commit is contained in:
Philip Rebohle 2022-07-30 20:38:04 +02:00
parent ec7de66419
commit 10e6d0ef8a
No known key found for this signature in database
GPG Key ID: C8CC613427A31C99
4 changed files with 0 additions and 15 deletions

View File

@ -105,10 +105,6 @@ namespace dxvk {
(imageExtent.height / 8) + (imageExtent.height % 8), (imageExtent.height / 8) + (imageExtent.height % 8),
1); 1);
// Reset the spec constants used...
if (specConstantValue)
m_context->setSpecConstant(VK_PIPELINE_BIND_POINT_COMPUTE, 0, 0);
m_transferCommands += 1; m_transferCommands += 1;
} }

View File

@ -213,8 +213,6 @@ namespace dxvk {
ctx->setSpecConstant(VK_PIPELINE_BIND_POINT_GRAPHICS, 0, srcView->imageInfo().sampleCount); ctx->setSpecConstant(VK_PIPELINE_BIND_POINT_GRAPHICS, 0, srcView->imageInfo().sampleCount);
ctx->setSpecConstant(VK_PIPELINE_BIND_POINT_GRAPHICS, 1, m_gammaView != nullptr); ctx->setSpecConstant(VK_PIPELINE_BIND_POINT_GRAPHICS, 1, m_gammaView != nullptr);
ctx->draw(3, 1, 0, 0); ctx->draw(3, 1, 0, 0);
ctx->setSpecConstant(VK_PIPELINE_BIND_POINT_GRAPHICS, 0, 0);
ctx->setSpecConstant(VK_PIPELINE_BIND_POINT_GRAPHICS, 1, 0);
} }
void DxvkSwapchainBlitter::resolve( void DxvkSwapchainBlitter::resolve(

View File

@ -66,7 +66,6 @@ namespace dxvk::hud {
VkExtent2D surfaceSize) { VkExtent2D surfaceSize) {
this->setupRendererState(ctx, surfaceFormat, surfaceSize); this->setupRendererState(ctx, surfaceFormat, surfaceSize);
this->renderHudElements(ctx); this->renderHudElements(ctx);
this->resetRendererState(ctx);
} }
@ -102,11 +101,6 @@ namespace dxvk::hud {
} }
void Hud::resetRendererState(const Rc<DxvkContext>& ctx) {
ctx->setSpecConstant(VK_PIPELINE_BIND_POINT_GRAPHICS, 0, 0);
}
void Hud::renderHudElements(const Rc<DxvkContext>& ctx) { void Hud::renderHudElements(const Rc<DxvkContext>& ctx) {
m_hudItems.render(m_renderer); m_hudItems.render(m_renderer);
} }

View File

@ -90,9 +90,6 @@ namespace dxvk::hud {
VkSurfaceFormatKHR surfaceFormat, VkSurfaceFormatKHR surfaceFormat,
VkExtent2D surfaceSize); VkExtent2D surfaceSize);
void resetRendererState(
const Rc<DxvkContext>& ctx);
void renderHudElements( void renderHudElements(
const Rc<DxvkContext>& ctx); const Rc<DxvkContext>& ctx);