mirror of
https://github.com/doitsujin/dxvk.git
synced 2025-01-19 05:52:11 +01:00
[dxvk] Change spec constant IDs
We no longer support per-resource spec constants, so there is no good reason not to use a 1:1 mapping for user-defined constants.
This commit is contained in:
parent
2e73e46799
commit
7c4d602863
@ -3,7 +3,7 @@
|
||||
|
||||
#include "d3d9_convert_common.h"
|
||||
|
||||
layout(constant_id = 1225) const bool s_is_uyvy = false;
|
||||
layout(constant_id = 0) const bool s_is_uyvy = false;
|
||||
|
||||
layout(
|
||||
local_size_x = 8,
|
||||
|
@ -152,7 +152,6 @@ namespace dxvk {
|
||||
|
||||
// Set up some specialization constants
|
||||
DxvkSpecConstants specData;
|
||||
specData.set(uint32_t(DxvkSpecConstantId::RasterizerSampleCount), sampleCount, VK_SAMPLE_COUNT_1_BIT);
|
||||
|
||||
for (uint32_t i = 0; i < MaxNumRenderTargets; i++) {
|
||||
if ((m_fsOut & (1 << i)) != 0) {
|
||||
|
@ -24,14 +24,10 @@ namespace dxvk {
|
||||
* implementation at pipeline compilation time.
|
||||
*/
|
||||
enum class DxvkSpecConstantId : uint32_t {
|
||||
FirstPipelineConstant = 0,
|
||||
/// Special constant ranges that do not count
|
||||
/// towards the spec constant min/max values
|
||||
ColorComponentMappings = MaxNumResourceSlots,
|
||||
|
||||
// Specialization constants for pipeline state
|
||||
SpecConstantRangeStart = ColorComponentMappings + MaxNumRenderTargets,
|
||||
RasterizerSampleCount = SpecConstantRangeStart + 0,
|
||||
FirstPipelineConstant
|
||||
ColorComponentMappings = DxvkLimits::MaxNumSpecConstants,
|
||||
};
|
||||
|
||||
/**
|
||||
|
@ -1,6 +1,6 @@
|
||||
#version 450
|
||||
|
||||
layout(constant_id = 1225) const bool srgbSwapchain = false;
|
||||
layout(constant_id = 0) const bool srgbSwapchain = false;
|
||||
|
||||
layout(location = 0) in vec2 v_coord;
|
||||
layout(location = 0) out vec4 o_color;
|
||||
|
@ -1,6 +1,6 @@
|
||||
#version 450
|
||||
|
||||
layout(constant_id = 1225) const bool srgbSwapchain = false;
|
||||
layout(constant_id = 0) const bool srgbSwapchain = false;
|
||||
|
||||
layout(binding = 2) uniform sampler2D s_font;
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
#version 450
|
||||
|
||||
layout(constant_id = 1226) const bool s_gamma_bound = false;
|
||||
layout(constant_id = 1) const bool s_gamma_bound = false;
|
||||
|
||||
layout(binding = 0) uniform sampler2D s_image;
|
||||
layout(binding = 1) uniform sampler1D s_gamma;
|
||||
|
@ -1,6 +1,6 @@
|
||||
#version 450
|
||||
|
||||
layout(constant_id = 1226) const bool s_gamma_bound = false;
|
||||
layout(constant_id = 1) const bool s_gamma_bound = false;
|
||||
|
||||
layout(binding = 0) uniform sampler2D s_image;
|
||||
layout(binding = 1) uniform sampler1D s_gamma;
|
||||
|
@ -1,7 +1,7 @@
|
||||
#version 450
|
||||
|
||||
layout(constant_id = 1225) const uint c_samples = 0;
|
||||
layout(constant_id = 1226) const bool s_gamma_bound = false;
|
||||
layout(constant_id = 0) const uint c_samples = 0;
|
||||
layout(constant_id = 1) const bool s_gamma_bound = false;
|
||||
|
||||
layout(binding = 0) uniform sampler2DMS s_image;
|
||||
layout(binding = 1) uniform sampler1D s_gamma;
|
||||
|
@ -2,8 +2,8 @@
|
||||
|
||||
#extension GL_AMD_shader_fragment_mask: enable
|
||||
|
||||
layout(constant_id = 1225) const uint c_samples = 0;
|
||||
layout(constant_id = 1226) const bool s_gamma_bound = false;
|
||||
layout(constant_id = 0) const uint c_samples = 0;
|
||||
layout(constant_id = 1) const bool s_gamma_bound = false;
|
||||
|
||||
layout(binding = 0) uniform sampler2DMS s_image;
|
||||
layout(binding = 1) uniform sampler1D s_gamma;
|
||||
|
Loading…
x
Reference in New Issue
Block a user