allow setting of pixel format/ocio method/sample format in preferences

Implementation isn't perfect yet, viewer/renderer doesn't update yet when
the preference is changed so a sequence needs to be re-opened for the change to
take effect.
This commit is contained in:
itsmattkc
2020-01-18 03:37:36 +11:00
parent e6b45c75c3
commit 1101b58ee8
30 changed files with 421 additions and 380 deletions
+11
View File
@@ -4,6 +4,7 @@
#include "common/define.h"
#include "config/config.h"
#include "core.h"
ColorManager::ColorManager()
{
@@ -110,6 +111,16 @@ QStringList ColorManager::ListAvailableInputColorspaces(OCIO::ConstConfigRcPtr c
return spaces;
}
ColorManager::OCIOMethod ColorManager::GetOCIOMethodForMode(RenderMode::Mode mode)
{
return static_cast<OCIOMethod>(Core::GetPreferenceForRenderMode(mode, QStringLiteral("OCIOMethod")).toInt());
}
void ColorManager::SetOCIOMethodForMode(RenderMode::Mode mode, ColorManager::OCIOMethod method)
{
Core::SetPreferenceForRenderMode(mode, QStringLiteral("OCIOMethod"), method);
}
void ColorManager::AssociateAlphaPixFmtFilter(ColorManager::AlphaAction action, FramePtr f)
{
int pixel_count = f->width() * f->height() * kRGBAChannels;