viewer/various: split off color management into separate base class

Also moves scopes to said base class.
This commit is contained in:
itsmattkc
2020-04-24 03:45:07 +10:00
18 changed files with 203 additions and 131 deletions
+4 -2
View File
@@ -27,10 +27,10 @@
OLIVE_NAMESPACE_ENTER
WaveformScope::WaveformScope(QWidget* parent) :
QOpenGLWidget(parent),
ManagedDisplayWidget(parent),
texture_(nullptr)
{
EnableDefaultContextMenu();
}
void WaveformScope::SetTexture(OpenGLTexture *texture)
@@ -42,6 +42,8 @@ void WaveformScope::SetTexture(OpenGLTexture *texture)
void WaveformScope::initializeGL()
{
ManagedDisplayWidget::initializeGL();
pipeline_ = OpenGLShader::Create();
pipeline_->create();
pipeline_->addShaderFromSourceCode(QOpenGLShader::Vertex, OpenGLShader::CodeDefaultVertex());