]> git.tdb.fi Git - libs/gl.git/blob - source/backends/vulkan/batch_backend.cpp
Support multiple PipelineStates in Renderer
[libs/gl.git] / source / backends / vulkan / batch_backend.cpp
1 #include <stdexcept>
2 #include "batch_backend.h"
3 #include "vulkan.h"
4
5 using namespace std;
6
7 namespace Msp {
8 namespace GL {
9
10 unsigned get_vulkan_index_type(DataType t)
11 {
12         switch(t)
13         {
14         case UNSIGNED_SHORT: return VK_INDEX_TYPE_UINT16;
15         case UNSIGNED_INT: return VK_INDEX_TYPE_UINT32;
16         default: throw invalid_argument("get_vulkan_index_type");
17         }
18 }
19
20 } // namespace GL
21 } // namespace Msp