digiKam Developer Documentation
Professional Photo Management with the Power of Open Source
Loading...
Searching...
No Matches
Digikam::IccManager Class Reference
Inheritance diagram for Digikam::IccManager:

Public Member Functions

 IccManager (const DImg &image, const ICCSettingsContainer &settings=IccSettings::instance() ->settings())
 Constructs an IccManager object.
IccTransform displaySoftProofingTransform (const IccProfile &deviceProfile, const IccProfile &displayProfile)
IccTransform displaySoftProofingTransform (const IccProfile &deviceProfile, QWidget *const displayingWidget=nullptr)
IccTransform displayTransform (const IccProfile &displayProfile)
IccTransform displayTransform (QWidget *const displayingWidget=nullptr)
bool hasValidWorkspace () const
DImg image () const
IccProfile imageProfile (ICCSettingsContainer::Behavior behavior, const IccProfile &specifiedProfile=IccProfile())
bool isMissingProfile () const
bool isProfileMismatch () const
bool isUncalibratedColor () const
DImgLoaderObserver * observer () const
void setObserver (DImgLoaderObserver *const observer)
ICCSettingsContainer settings () const
void transform (ICCSettingsContainer::Behavior behavior, const IccProfile &specifiedProfile=IccProfile())
 Same as above, but not using default settings but the given settings.
void transformDefault ()
 Transforms the image for full editing, using default settings.
void transformForDisplay ()
 Transforms the image for display on screen.
void transformForDisplay (const IccProfile &displayProfile)
void transformForDisplay (QWidget *const widget)
void transformForOutput (const IccProfile &outputProfile)
 Transforms the image for output to the specified output profile.
void transformToSRGB ()
 Transforms the image to sRGB.

Static Public Member Functions

static IccProfile displayProfile (QWidget *const displayingWidget=nullptr)
static bool isSRGB (const DImg &img)
static bool needsPostLoadingManagement (const DImg &img)
static void transformForDisplay (QImage &qimage, const IccProfile &displayProfile1=displayProfile())
 Transforms the given QImage from sRGB to given display profile.
static void transformToSRGB (QImage &qimage, const IccProfile &inputProfile)
 Transforms the given QImage from the given inputProfile to sRGB.

Protected Member Functions

void getTransform (IccTransform &trans, ICCSettingsContainer::Behavior behavior, const IccProfile &specifiedProfile)
ICCSettingsContainer::Behavior safestBestBehavior () const
void setIccProfile (const IccProfile &profile)

Constructor & Destructor Documentation

◆ IccManager()

Digikam::IccManager::IccManager ( const DImg & image,
const ICCSettingsContainer & settings = IccSettings::instance()->settings() )
explicit

The DImg will be edited. The filePath is for display only.

Member Function Documentation

◆ displaySoftProofingTransform()

IccTransform Digikam::IccManager::displaySoftProofingTransform ( const IccProfile & deviceProfile,
QWidget *const displayingWidget = nullptr )
Returns
a display transform, with soft-proofing enabled for the given device profile.

◆ imageProfile()

IccProfile Digikam::IccManager::imageProfile ( ICCSettingsContainer::Behavior behavior,
const IccProfile & specifiedProfile = IccProfile() )
Returns
the profile that will be used to interpret the image, using the given behavior

◆ isSRGB()

bool Digikam::IccManager::isSRGB ( const DImg & img)
static
Returns
true if a call to transformToSRGB() would have an effect.

◆ needsPostLoadingManagement()

bool Digikam::IccManager::needsPostLoadingManagement ( const DImg & img)
static
Returns
true if the given image is marked as needing user interaction for further color management decision after loading. If this returns true, use IccPostLoadingManager to do this.

◆ transformDefault()

void Digikam::IccManager::transformDefault ( )

If the default settings require showing a dialog, the image is marked as such but no action is taken. See IccPostLoadingManager.

◆ transformForDisplay()

void Digikam::IccManager::transformForDisplay ( )

The result is not suitable for editing or storage. You can specify the widget in which the image will be displayed, or specify the display profile yourself. You can retrieve the profile with displayProfile() and pass it to transformForDisplay() later (in a thread), or you can get a transform from displayTransform and apply it yourself.