1 module dmagick.c.profile;
2 
3 import dmagick.c.magickString;
4 import dmagick.c.image;
5 import dmagick.c.magickType;
6 
7 extern(C)
8 {
9 	struct ProfileInfo
10 	{
11 		char*
12 			name;
13 
14 		size_t
15 			length;
16 
17 		ubyte*
18 			info;
19 
20 		size_t
21 			signature;
22 	}
23 
24 	/**
25 	 * Rendering intent is a concept defined by ICC Spec ICC.1:1998-09,
26 	 * "File Format for Color Profiles". ImageMagick uses RenderingIntent in
27 	 * order to support ICC Color Profiles.
28 	 * 
29 	 * From the specification: "Rendering intent specifies the style of
30 	 * reproduction to be used during the evaluation of this profile in a
31 	 * sequence of profiles. It applies specifically to that profile in the
32 	 * sequence and not to the entire sequence. Typically, the user or
33 	 * application will set the rendering intent dynamically at runtime or
34 	 * embedding time."
35 	 */
36 	enum RenderingIntent
37 	{
38 		/**
39 		 * No intent has been specified.
40 		 */
41 		UndefinedIntent,
42 
43 		/**
44 		 * A rendering intent that specifies the saturation of the pixels in
45 		 * the image is preserved perhaps at the expense of accuracy in hue
46 		 * and lightness.
47 		 */
48 		SaturationIntent,
49 
50 		/**
51 		 * A rendering intent that specifies the full gamut of the image is
52 		 * compressed or expanded to fill the gamut of the destination
53 		 * device. Gray balance is preserved but colorimetric accuracy might
54 		 * not be preserved.
55 		 */
56 		PerceptualIntent,
57 
58 		/**
59 		 * Absolute colorimetric.
60 		 */
61 		AbsoluteIntent,
62 
63 		/**
64 		 * Relative colorimetric.
65 		 */
66 		RelativeIntent
67 	}
68 
69 	char* GetNextImageProfile(const(Image)*);
70 
71 	const(StringInfo)* GetImageProfile(const(Image)*, const(char)*);
72 
73 	MagickBooleanType CloneImageProfiles(Image*, const(Image)*);
74 	MagickBooleanType DeleteImageProfile(Image*, const(char)*);
75 	MagickBooleanType ProfileImage(Image*, const(char)*, const(void)*, const size_t, const MagickBooleanType);
76 	MagickBooleanType SetImageProfile(Image*, const(char)*, const(StringInfo)*);
77 	MagickBooleanType SyncImageProfiles(Image*);
78 
79 	StringInfo* RemoveImageProfile(Image*, const(char)*);
80 
81 	void DestroyImageProfiles(Image*);
82 	void ResetImageProfileIterator(const(Image)*);
83 }