diff options
| author | 2020-03-15 04:04:17 -0300 | |
|---|---|---|
| committer | 2020-03-15 04:04:17 -0300 | |
| commit | a7131af7d6714b9ad3851e76c80c6c5ca4f696cf (patch) | |
| tree | dc1345ff6018006a311f6a8b5672716a91dfc99f /src/video_core | |
| parent | Merge pull request #3508 from FernandoS27/page-table (diff) | |
| download | yuzu-a7131af7d6714b9ad3851e76c80c6c5ca4f696cf.tar.gz yuzu-a7131af7d6714b9ad3851e76c80c6c5ca4f696cf.tar.xz yuzu-a7131af7d6714b9ad3851e76c80c6c5ca4f696cf.zip | |
vk_rasterizer: Fix vertex range assert
End can be equal to start in CalculateVertexArraysSize. This is quite
common when the vertex size is zero.
Diffstat (limited to 'src/video_core')
| -rw-r--r-- | src/video_core/renderer_vulkan/vk_rasterizer.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/video_core/renderer_vulkan/vk_rasterizer.cpp b/src/video_core/renderer_vulkan/vk_rasterizer.cpp index f889019c1..c9886cc16 100644 --- a/src/video_core/renderer_vulkan/vk_rasterizer.cpp +++ b/src/video_core/renderer_vulkan/vk_rasterizer.cpp | |||
| @@ -1151,7 +1151,7 @@ std::size_t RasterizerVulkan::CalculateVertexArraysSize() const { | |||
| 1151 | // This implementation assumes that all attributes are used in the shader. | 1151 | // This implementation assumes that all attributes are used in the shader. |
| 1152 | const GPUVAddr start{regs.vertex_array[index].StartAddress()}; | 1152 | const GPUVAddr start{regs.vertex_array[index].StartAddress()}; |
| 1153 | const GPUVAddr end{regs.vertex_array_limit[index].LimitAddress()}; | 1153 | const GPUVAddr end{regs.vertex_array_limit[index].LimitAddress()}; |
| 1154 | DEBUG_ASSERT(end > start); | 1154 | DEBUG_ASSERT(end >= start); |
| 1155 | 1155 | ||
| 1156 | size += (end - start + 1) * regs.vertex_array[index].enable; | 1156 | size += (end - start + 1) * regs.vertex_array[index].enable; |
| 1157 | } | 1157 | } |