Add depth bias config to shader
This commit is contained in:
@@ -11,39 +11,36 @@
|
||||
#include <vulkan/vulkan.hpp>
|
||||
#include <vector>
|
||||
|
||||
namespace OpenVulkano
|
||||
namespace OpenVulkano::Vulkan
|
||||
{
|
||||
namespace Vulkan
|
||||
{
|
||||
class Context;
|
||||
class IShaderOwner;
|
||||
class Context;
|
||||
class IShaderOwner;
|
||||
|
||||
class VulkanShader final : public IRenderResource<Scene::Shader>, public IRecordable
|
||||
{
|
||||
public:
|
||||
vk::Device device;
|
||||
std::vector<vk::ShaderModule> shaderModules; // TODO manage live time somewhere else to allow sharing of shader programs
|
||||
std::vector<vk::PipelineShaderStageCreateInfo> shaderStageCreateInfo;
|
||||
vk::Pipeline pipeline; // TODO pipeline and shader config should be split
|
||||
std::vector<vk::DescriptorSetLayout> descriptorSetLayouts;
|
||||
vk::PipelineLayout pipelineLayout;
|
||||
IShaderOwner* owner = nullptr;
|
||||
Context* context = nullptr;
|
||||
{
|
||||
public:
|
||||
vk::Device device;
|
||||
std::vector<vk::ShaderModule> shaderModules; // TODO manage live time somewhere else to allow sharing of shader programs
|
||||
std::vector<vk::PipelineShaderStageCreateInfo> shaderStageCreateInfo;
|
||||
vk::Pipeline pipeline; // TODO pipeline and shader config should be split
|
||||
std::vector<vk::DescriptorSetLayout> descriptorSetLayouts;
|
||||
vk::PipelineLayout pipelineLayout;
|
||||
IShaderOwner* owner = nullptr;
|
||||
Context* context = nullptr;
|
||||
|
||||
VulkanShader(Context* context, Scene::Shader* shader, IShaderOwner* owner);
|
||||
VulkanShader(Context* context, Scene::Shader* shader, IShaderOwner* owner);
|
||||
|
||||
~VulkanShader() override;
|
||||
~VulkanShader() override;
|
||||
|
||||
void Resize();
|
||||
void Resize();
|
||||
|
||||
void Record(VulkanDrawContext* context) override;
|
||||
void Record(VulkanDrawContext* context) override;
|
||||
|
||||
void Release() override;
|
||||
void Release() override;
|
||||
|
||||
private:
|
||||
void BuildPipeline();
|
||||
private:
|
||||
void BuildPipeline();
|
||||
|
||||
void CreatePipelineLayout();
|
||||
};
|
||||
}
|
||||
void CreatePipelineLayout();
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user