added functions to override the resolution and matrix transform of the viewer widget

While in most circumstances these shouldn't be used, they're useful for
showing things like export previews
This commit is contained in:
itsmattkc
2019-12-19 15:55:08 +11:00
parent c5e16ed805
commit 0ef00245ad
4 changed files with 33 additions and 1 deletions
+7 -1
View File
@@ -69,6 +69,12 @@ void ViewerGLWidget::DisconnectColorManager()
ConnectColorManager(nullptr);
}
void ViewerGLWidget::SetMatrix(const QMatrix4x4 &mat)
{
matrix_ = mat;
update();
}
void ViewerGLWidget::SetOCIODisplay(const QString &display)
{
ocio_display_ = display;
@@ -135,7 +141,7 @@ void ViewerGLWidget::paintGL()
f->glBindTexture(GL_TEXTURE_2D, texture_);
// Blit using the pipeline retrieved in initializeGL()
olive::gl::OCIOBlit(pipeline_, ocio_lut_, true);
olive::gl::OCIOBlit(pipeline_, ocio_lut_, true, matrix_);
// Release retrieved texture
f->glBindTexture(GL_TEXTURE_2D, 0);