annotate dstep/applicationservices/coregraphics/CGDirectPalette.d @ 12:9f0b49a2f64e

Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
author Jacob Carlborg <doob@me.com>
date Mon, 03 Aug 2009 14:00:21 +0200
parents
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
12
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
1 /**
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
2 * Copyright: Copyright (c) 2009 Jacob Carlborg.
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
3 * Authors: Jacob Carlborg
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
4 * Version: Initial created: Aug 1, 2009
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
5 * License: $(LINK2 http://www.boost.org/LICENSE_1_0.txt, Boost Software License 1.0)
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
6 */
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
7 module dstep.applicationservices.coregraphics.CGDirectPalette;
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
8
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
9 import dstep.applicationservices.coregraphics.CGDirectDisplay;
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
10
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
11 alias float CGPaletteBlendFraction;
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
12 alias _CGDeviceColor CGDeviceColor;
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
13 alias _CGDeviceByteColor CGDeviceByteColor;
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
14
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
15 struct _CGDeviceColor
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
16 {
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
17 float red;
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
18 float green;
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
19 float blue;
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
20 }
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
21
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
22
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
23 struct _CGDeviceByteColor
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
24 {
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
25 ubyte red;
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
26 ubyte green;
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
27 ubyte blue;
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
28 }
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
29
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
30 extern (C)
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
31 {
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
32 CGDirectPaletteRef CGPaletteCreateDefaultColorPalette ();
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
33 CGDirectPaletteRef CGPaletteCreateWithDisplay (uint display);
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
34 CGDirectPaletteRef CGPaletteCreateWithCapacity (uint capacity);
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
35 CGDirectPaletteRef CGPaletteCreateWithSamples (CGDeviceColor* sampleTable, uint sampleCount);
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
36 CGDirectPaletteRef CGPaletteCreateWithByteSamples (CGDeviceByteColor* sampleTable, uint sampleCount);
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
37 void CGPaletteRelease (CGDirectPaletteRef palette);
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
38 CGDeviceColor CGPaletteGetColorAtIndex (CGDirectPaletteRef palette, uint index);
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
39 uint CGPaletteGetIndexForColor (CGDirectPaletteRef palette, CGDeviceColor color);
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
40 uint CGPaletteGetNumberOfSamples (CGDirectPaletteRef palette);
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
41 void CGPaletteSetColorAtIndex (CGDirectPaletteRef palette, CGDeviceColor color, uint index);
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
42 CGDirectPaletteRef CGPaletteCreateCopy (CGDirectPaletteRef palette);
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
43 ubyte CGPaletteIsEqualToPalette (CGDirectPaletteRef palette1, CGDirectPaletteRef palette2);
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
44 CGDirectPaletteRef CGPaletteCreateFromPaletteBlendedWithColor (CGDirectPaletteRef palette, float fraction, CGDeviceColor color);
9f0b49a2f64e Added the ApplicationServices frameworks: ATS, ColorSync and CoreGraphics
Jacob Carlborg <doob@me.com>
parents:
diff changeset
45 }