mirror of
https://github.com/redstrate/Novus.git
synced 2025-04-22 03:57:45 +00:00
This is only needed for additional GLSL debug information, and is definitely not required.
28 lines
No EOL
669 B
C++
28 lines
No EOL
669 B
C++
// SPDX-FileCopyrightText: 2024 Joshua Goins <josh@redstrate.com>
|
|
// SPDX-License-Identifier: GPL-3.0-or-later
|
|
|
|
#pragma once
|
|
|
|
#include <string_view>
|
|
#include <vector>
|
|
|
|
#include <physis.hpp>
|
|
#include <spirv.hpp>
|
|
#include <spirv_glsl.hpp>
|
|
#include <vulkan/vulkan.h>
|
|
|
|
class Device;
|
|
|
|
class ShaderManager
|
|
{
|
|
public:
|
|
explicit ShaderManager(Device &device);
|
|
|
|
spirv_cross::CompilerGLSL getShaderModuleResources(const physis_Shader &shader);
|
|
VkShaderModule convertShaderModule(const physis_Shader &shader, spv::ExecutionModel executionModel);
|
|
|
|
private:
|
|
std::vector<uint32_t> compileGLSL(std::string_view sourceString, ShaderStage stage);
|
|
|
|
Device &m_device;
|
|
}; |