Scribus
Open source desktop publishing at your fingertips
sccolormgmtenginedata.h
1 /*
2 For general Scribus (>=1.3.2) copyright and licensing information please refer
3 to the COPYING file provided with the program. Following this notice may exist
4 a copyright and/or license notice that predates the release of Scribus 1.3.2
5 for which a new license (GPL+exception) is in place.
6 */
7 
8 #ifndef SCCOLORMGMTENGINEDATA_H
9 #define SCCOLORMGMTENGINEDATA_H
10 
11 #include <QByteArray>
12 #include <QString>
13 
14 #include "sccolormgmtstructs.h"
15 #include "sccolorprofile.h"
16 #include "sccolorspace.h"
17 #include "sccolortransform.h"
18 #include "sccolortransformpool.h"
19 
20 class ScColorMgmtEngine;
21 
23 {
24 protected:
25  int m_engineID;
26  QString m_description;
27  ScColorMgmtStrategy m_strategy;
28 
29 public:
30 
31  ScColorMgmtEngineData(const QString& desc, int uniqueID) : m_engineID(uniqueID),
32  m_description(desc)
33  {}
34  virtual ~ScColorMgmtEngineData() {};
35 
36  // Getters
37  int engineID() const { return m_engineID; }
38  const QString& description() const { return m_description; }
39  const ScColorMgmtStrategy& strategy() const { return m_strategy; }
40 
41  // Setter, only for color management strategy, and purely virtual ;)
42  virtual void setStrategy(const ScColorMgmtStrategy& strategy) = 0;
43 
44  // function for getting available profile in a directory
45  virtual QList<ScColorProfileInfo> getAvailableProfileInfo(const QString& directory, bool recursive) = 0;
46 
47  // functions for opening icc profiles
48  virtual ScColorProfile openProfileFromFile(ScColorMgmtEngine& engine, const QString& filePath) = 0;
49  virtual ScColorProfile openProfileFromMem (ScColorMgmtEngine& engine, const QByteArray& array) = 0;
50 
51  // functions for creating profiles
52  virtual ScColorProfile createProfile_sRGB(ScColorMgmtEngine& engine) = 0;
53  virtual ScColorProfile createProfile_Lab (ScColorMgmtEngine& engine) = 0;
54 
55  // functions for creating transforms
56  virtual ScColorTransform createTransform(ScColorMgmtEngine& colorManagementEngine,
57  const ScColorProfile& inputProfile , eColorFormat inputFormat,
58  const ScColorProfile& outputProfile, eColorFormat outputFormat,
59  eRenderIntent renderIntent, long transformFlags) = 0;
60  virtual ScColorTransform createProofingTransform(ScColorMgmtEngine& colorManagementEngine,
61  const ScColorProfile& inputProfile , eColorFormat inputFormat,
62  const ScColorProfile& outputProfile, eColorFormat outputFormat,
63  const ScColorProfile& proofing, eRenderIntent renderIntent,
64  eRenderIntent proofingIntent, long transformFlags) = 0;
65 
66  virtual ScColorSpace createColorSpace(ScColorProfile& profile, eColorFormat colorFormat);
67 };
68 
69 #endif
Definition: sccolorspace.h:18
Definition: sccolorprofile.h:16
Definition: sccolormgmtenginedata.h:22
Definition: sccolortransform.h:16
Definition: sccolormgmtstructs.h:92
Definition: sccolormgmtengine.h:16