summaryrefslogtreecommitdiff
path: root/Source/Core/VideoBackends
diff options
context:
space:
mode:
authorShawn Hoffman <godisgovernment@gmail.com>2020-08-17 17:30:49 -0700
committerShawn Hoffman <godisgovernment@gmail.com>2020-08-23 13:57:05 -0700
commit938fd4e43871d281f5efa185a5b62b8b74fa13f3 (patch)
treeb0c89093566977129d30191877893cb8649cc897 /Source/Core/VideoBackends
parent79f5ea04744a50c006067800d506211553757387 (diff)
use constexpr for some compile-time expressions
Diffstat (limited to 'Source/Core/VideoBackends')
-rw-r--r--Source/Core/VideoBackends/D3D12/VertexManager.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/Source/Core/VideoBackends/D3D12/VertexManager.cpp b/Source/Core/VideoBackends/D3D12/VertexManager.cpp
index bdf5fbe8e8..ecaec7c9c1 100644
--- a/Source/Core/VideoBackends/D3D12/VertexManager.cpp
+++ b/Source/Core/VideoBackends/D3D12/VertexManager.cpp
@@ -195,10 +195,10 @@ void VertexManager::UploadAllConstants()
{
// We are free to re-use parts of the buffer now since we're uploading all constants.
const u32 pixel_constants_offset = 0;
- const u32 vertex_constants_offset =
+ constexpr u32 vertex_constants_offset =
Common::AlignUp(pixel_constants_offset + sizeof(PixelShaderConstants),
D3D12_CONSTANT_BUFFER_DATA_PLACEMENT_ALIGNMENT);
- const u32 geometry_constants_offset =
+ constexpr u32 geometry_constants_offset =
Common::AlignUp(vertex_constants_offset + sizeof(VertexShaderConstants),
D3D12_CONSTANT_BUFFER_DATA_PLACEMENT_ALIGNMENT);
const u32 allocation_size = geometry_constants_offset + sizeof(GeometryShaderConstants);