use config for viewer reassoc

Fixes #1661
This commit is contained in:
itsmattkc
2021-12-02 13:15:09 -08:00
parent 1828c2fd73
commit cfab883374
3 changed files with 7 additions and 2 deletions
+1
View File
@@ -100,6 +100,7 @@ void Config::SetDefaults()
SetEntryInternal(QStringLiteral("ShowClipWhileDragging"), NodeValue::kBoolean, true);
SetEntryInternal(QStringLiteral("StopPlaybackOnLastFrame"), NodeValue::kBoolean, false);
SetEntryInternal(QStringLiteral("UseLegacyColorInInputTab"), NodeValue::kBoolean, false);
SetEntryInternal(QStringLiteral("ReassocLinToNonLin"), NodeValue::kBoolean, false);
SetEntryInternal(QStringLiteral("AutoCacheDelay"), NodeValue::kInt, 1000);
+3 -1
View File
@@ -96,7 +96,9 @@ FramePtr RenderProcessor::GenerateFrame(TexturePtr texture, const rational& time
if (output_color_transform) {
// Yes color transform, blit color managed
render_ctx_->BlitColorManaged(output_color_transform, texture, Renderer::kAlphaNone, blit_tex.get(), true, matrix);
render_ctx_->BlitColorManaged(output_color_transform, texture,
Config::Current()[QStringLiteral("ReassocLinToNonLin")].toBool() ? Renderer::kAlphaAssociated : Renderer::kAlphaNone,
blit_tex.get(), true, matrix);
} else {
// No color transform, just blit
ShaderJob job;
+3 -1
View File
@@ -391,7 +391,9 @@ void ViewerDisplayWidget::OnPaint()
texture_to_draw = deinterlace_texture_;
}
renderer()->BlitColorManaged(color_service(), texture_to_draw, Renderer::kAlphaNone, device_params, false,
renderer()->BlitColorManaged(color_service(), texture_to_draw,
Config::Current()[QStringLiteral("ReassocLinToNonLin")].toBool() ? Renderer::kAlphaAssociated : Renderer::kAlphaNone,
device_params, false,
combined_matrix_flipped_, crop_matrix_);
}
}