Route colorize mask and slider shader setup through helpers
This commit is contained in:
@@ -3,6 +3,7 @@
|
||||
#include "app_core/app_dialog.h"
|
||||
#include "foundation/result.h"
|
||||
#include "node.h"
|
||||
#include "shader.h"
|
||||
|
||||
#include <functional>
|
||||
#include <memory>
|
||||
@@ -15,6 +16,20 @@ class NodeProgressBar;
|
||||
|
||||
namespace pp::panopainter {
|
||||
|
||||
inline void configure_legacy_slider_color_shader(const glm::mat4& mvp) noexcept
|
||||
{
|
||||
ShaderManager::use(kShader::Color);
|
||||
ShaderManager::u_mat4(kShaderUniform::MVP, mvp);
|
||||
ShaderManager::u_vec4(kShaderUniform::Col, { 0, 0, 0, 1 });
|
||||
}
|
||||
|
||||
inline void configure_legacy_slider_hue_shader(const glm::mat4& mvp, int direction) noexcept
|
||||
{
|
||||
ShaderManager::use(kShader::ColorHue);
|
||||
ShaderManager::u_mat4(kShaderUniform::MVP, mvp);
|
||||
ShaderManager::u_int(kShaderUniform::Direction, direction);
|
||||
}
|
||||
|
||||
void initialize_legacy_overlay_node(App& app, Node& node);
|
||||
|
||||
void destroy_legacy_node(Node& node);
|
||||
|
||||
Reference in New Issue
Block a user