Commit 342b87f3 authored by Boudewijn Rempt's avatar Boudewijn Rempt

Add a hidden config option to set the default exr F16/F32 profile

Exr files don't have profiles, and profiles are totally irrelevant
for exr/hdr workflow: the lut docker is what is used in these cases.
But since we need to set a profile on a krita image, let's make it
configurable at least.

Note: there's no gui for this because a) it's an advanced option
and b) we're in string freeze.

CCMAIL:kimageshop@kde.org
BUG:406939
parent ca927d0b
......@@ -197,11 +197,13 @@ ImageType imfTypeToKisType(Imf::PixelType type)
const KoColorSpace* kisTypeToColorSpace(QString model, ImageType imageType)
{
const QString profileName = KisConfig(false).readEntry("ExrDefaultColorProfile", KoColorSpaceRegistry::instance()->defaultProfileForColorSpace(model));
switch (imageType) {
case IT_FLOAT16:
return KoColorSpaceRegistry::instance()->colorSpace(model, Float16BitsColorDepthID.id(), "");
return KoColorSpaceRegistry::instance()->colorSpace(model, Float16BitsColorDepthID.id(), profileName);
case IT_FLOAT32:
return KoColorSpaceRegistry::instance()->colorSpace(model, Float32BitsColorDepthID.id(), "");
return KoColorSpaceRegistry::instance()->colorSpace(model, Float32BitsColorDepthID.id(), profileName);
case IT_UNKNOWN:
case IT_UNSUPPORTED:
return 0;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment