17#include <vsg/vk/Device.h>
18#include <vsg/vk/vk_buffer.h>
38 SPIRV_1_0 = (1 << 16),
39 SPIRV_1_1 = (1 << 16) | (1 << 8),
40 SPIRV_1_2 = (1 << 16) | (2 << 8),
41 SPIRV_1_3 = (1 << 16) | (3 << 8),
42 SPIRV_1_4 = (1 << 16) | (4 << 8),
43 SPIRV_1_5 = (1 << 16) | (5 << 8)
46 uint32_t vulkanVersion = VK_API_VERSION_1_0;
47 int clientInputVersion = 100;
48 Language language = GLSL;
49 int defaultVersion = 450;
50 SpirvTarget target = SPIRV_1_0;
51 bool forwardCompatible =
false;
52 bool generateDebugInfo =
false;
54 std::set<std::string> defines;
59 void read(
Input& input)
override;
60 void write(
Output& output)
const override;
69 using SPIRV = std::vector<uint32_t>;
74 ShaderModule(
const std::string& source,
const SPIRV& in_code);
83 VkShaderModule
vk(uint32_t deviceID)
const {
return _implementation[deviceID]->_shaderModule; }
89 void release(uint32_t deviceID) { _implementation[deviceID] = {}; }
90 void release() { _implementation.clear(); }
95 void read(
Input& input)
override;
96 void write(
Output& output)
const override;
107 VkShaderModule _shaderModule;
116 extern VSG_DECLSPEC std::string insertIncludes(
const std::string& source,
ref_ptr<const Options> options);
Device encapsulates VkDevice, a logical handle to the PhysicalDevice with capabilities specified duri...
Definition Device.h:37
Definition ShaderModule.h:28
int compare(const Object &rhs_object) const override
compare two objects, return -1 if this object is less than rhs, return 0 if it's equal,...
Definition ShaderModule.h:67
VkShaderModule vk(uint32_t deviceID) const
Vulkan VkShaderModule handle.
Definition ShaderModule.h:83
SPIRV code
VkShaderModuleCreateInfo settings.
Definition ShaderModule.h:80
int compare(const Object &rhs_object) const override
compare two objects, return -1 if this object is less than rhs, return 0 if it's equal,...
Definition ShaderModule.h:102
vk_buffer that manages a single logical device supported.
Definition vk_buffer.h:28