histogram: implemented color management
This commit is contained in:
@@ -68,6 +68,7 @@ ViewerWidget::ViewerWidget(QWidget *parent) :
|
||||
connect(main_widget, &ViewerGLWidget::LoadedBuffer, this, &ViewerWidget::LoadedBuffer);
|
||||
connect(main_widget, &ViewerGLWidget::LoadedTexture, this, &ViewerWidget::LoadedTexture);
|
||||
connect(main_widget, &ViewerGLWidget::DrewManagedTexture, this, &ViewerWidget::DrewManagedTexture);
|
||||
connect(main_widget, &ViewerGLWidget::ColorProcessorChanged, this, &ViewerWidget::ColorProcessorChanged);
|
||||
connect(sizer_, &ViewerSizer::RequestMatrix, main_widget, &ViewerGLWidget::SetMatrix);
|
||||
sizer_->SetWidget(main_widget);
|
||||
gl_widgets_.append(main_widget);
|
||||
|
||||
@@ -159,6 +159,11 @@ signals:
|
||||
*/
|
||||
void RequestScopePanel(ScopePanel::Type type);
|
||||
|
||||
/**
|
||||
* @brief Wrapper for ViewerGLWidget::ColorProcessorChanged()
|
||||
*/
|
||||
void ColorProcessorChanged(ColorProcessorPtr processor);
|
||||
|
||||
protected:
|
||||
virtual void TimebaseChangedEvent(const rational &) override;
|
||||
virtual void TimeChangedEvent(const int64_t &) override;
|
||||
|
||||
@@ -489,6 +489,9 @@ void ViewerGLWidget::SetupColorProcessor()
|
||||
} else {
|
||||
color_service_ = nullptr;
|
||||
}
|
||||
|
||||
qDebug() << "Emitting" << std::static_pointer_cast<ColorProcessor>(color_service_).get();
|
||||
emit ColorProcessorChanged(std::static_pointer_cast<ColorProcessor>(color_service_));
|
||||
}
|
||||
|
||||
void ViewerGLWidget::ContextCleanup()
|
||||
|
||||
@@ -189,6 +189,11 @@ signals:
|
||||
*/
|
||||
void DrewManagedTexture(OpenGLTexture* texture);
|
||||
|
||||
/**
|
||||
* @brief Emitted when the color processor changes
|
||||
*/
|
||||
void ColorProcessorChanged(ColorProcessorPtr processor);
|
||||
|
||||
protected:
|
||||
/**
|
||||
* @brief Override the mouse press event simply to emit the DragStarted() signal
|
||||
|
||||
Reference in New Issue
Block a user