1
Fork 0
mirror of https://github.com/redstrate/Novus.git synced 2025-04-22 12:07:45 +00:00
novus/renderer/include/shadermanager.h
Joshua Goins f63dcbe9b0 Make Dawntrail geometry rendering work
The biggest change is making the model data read from vertex streams,
like how the retail client is doing. The vertex bindings/locations
should be fixed, resilient for the future and work across more shader
packages.
2024-11-03 11:05:30 -05:00

29 lines
743 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 getShaderModuleTest(const physis_Shader &shader);
std::string getShaderModuleResources(const physis_Shader &shader, int i);
VkShaderModule convertShaderModule(const physis_Shader &shader, spv::ExecutionModel executionModel);
private:
std::vector<uint32_t> compileGLSL(std::string_view sourceString, ShaderStage stage);
Device &m_device;
};