mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-05 02:51:49 +00:00
refactor GLSLExtension.cpp & add 'param' shader preprocessor directive & add PostEffect class (WIP)
This commit is contained in:
parent
531334f059
commit
1feee3a809
8 changed files with 263 additions and 97 deletions
15
src/graphics/core/PostEffect.cpp
Normal file
15
src/graphics/core/PostEffect.cpp
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
#include "PostEffect.hpp"
|
||||
|
||||
#include "Shader.hpp"
|
||||
|
||||
PostEffect::Param::Param() : type(Type::FLOAT) {}
|
||||
|
||||
PostEffect::Param::Param(Type type) : type(type) {}
|
||||
|
||||
PostEffect::PostEffect(std::unique_ptr<Shader> shader)
|
||||
: shader(std::move(shader)) {
|
||||
}
|
||||
|
||||
void PostEffect::use() {
|
||||
shader->use();
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue