blob: b1be8a8c9c4484f25d1bc9b60d1d24cac63e3791 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
#pragma once
#include <cstdint>
#include <cstdlib>
#include <string>
#include <string_view>
#include <vector>
namespace iris {
struct ShaderDesc {
// Name of the shader, filename if loaded from file
std::string name;
// Source code of the shader
std::string source;
// Shader type
enum struct Type {
eRayGen,
eMiss,
eClosestHit,
eAnyHit,
eIntersection,
eCompute,
} type;
// Compiled binary
std::vector<uint32_t> compiled_binary;
static Type shader_type_from_string(std::string_view type);
ShaderDesc(const std::string_view path);
};
} // namespace iris
|