linux-wallpaperengine/src/WallpaperEngine/Render/Shaders/Variables/CShaderVariableVector3.cpp
Alexis Maiquez 291b7e364a - removed/commented out most irrlicht-specific code
~ written close to equivalent versions in OpenGL code using GLM and GLFW
~ written replacements for texture and package loading to not use irrlicht anymore
~ updated shader compiler as we now don't need to replace attributes anymore
+ added support for texture flags in the texture header (as they're needed for opengl to get proper information)

TODO: REWRITE VIDEO PLAYER SUPPORT AS THIS UPDATE EFFECTIVELY BREAKS IT

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2021-08-31 01:14:08 +02:00

31 lines
828 B
C++

#include "CShaderVariableVector3.h"
using namespace WallpaperEngine::Render::Shaders::Variables;
CShaderVariableVector3::CShaderVariableVector3 (const glm::vec3& defaultValue) :
m_defaultValue (defaultValue),
m_value (glm::vec3 ()),
CShaderVariable (&this->m_defaultValue, nullptr, Type)
{
}
CShaderVariableVector3::CShaderVariableVector3 (const glm::vec3& defaultValue, std::string name) :
m_defaultValue (defaultValue),
m_value (glm::vec3 ()),
CShaderVariable (&this->m_defaultValue, nullptr, Type)
{
this->setName (name);
}
void CShaderVariableVector3::setValue (const glm::vec3& value)
{
this->m_value = value;
CShaderVariable::setValue (&this->m_value);
}
const int CShaderVariableVector3::getSize () const
{
return 3;
}
const std::string CShaderVariableVector3::Type = "vec3";