My Project
 
Loading...
Searching...
No Matches
i-shader.h
Go to the documentation of this file.
1// Copyright (c) 2025 Milton McDonald
2// This source code is licensed under the MIT License. See LICENSE file in the
3// project root for details.
4
5#ifndef ENGINE_LIB_I_SHADER_H_
6#define ENGINE_LIB_I_SHADER_H_
7
8#include <memory>
9
10#include "dll-export.h"
11#include "types.h"
12
14
15class IShader {
16 public:
17 virtual ~IShader() = default;
18
19 [[nodiscard]] virtual auto GetProgramId() const -> unsigned int = 0;
20};
21
22using IShaderPtr = std::unique_ptr<IShader>;
23DLLEXPORT [[nodiscard]] auto CreateIShader(
24 const types::ShaderSourceMap& sources) -> IShaderPtr;
25
26} // namespace graphics_engine::shader
27
28#endif // ENGINE_LIB_I_SHADER_H_
Definition i-shader.h:15
virtual auto GetProgramId() const -> unsigned int=0
#define DLLEXPORT
Definition dll-export.h:19
Definition i-shader.h:13
std::unique_ptr< IShader > IShaderPtr
Definition i-shader.h:22
DLLEXPORT auto CreateIShader(const types::ShaderSourceMap &sources) -> IShaderPtr