PixelPacket Structure
The PixelPacket structure is used to represent pixels in ImageMagick. ImageMagick may be compiled to support 32 or 64 bit pixels. The size of PixelPacket is controlled by the value of the QuantumDepth define. The default is 64 bit pixels, which provide the best accuracy. If memory consumption must be minimized, or processing time must be minimized, then ImageMagick may be compiled with QuantumDepth=8. The following table shows the relationship between QuantumDepth, the type of Quantum, and the overall PixelPacket size.
Effect Of QuantumDepth Values
QuantumDepth
Quantum Type
PixelPacket Size
8
unsigned char
32 bits
16
unsigned short
64 bits
The members of the PixelPacket structure, and their interpretation, are shown in the following table:
PixelPacket Structure Members
Member
Type
Interpretation
Enumerations.html#ColorspaceTypeRGBColorspace 
Enumerations.html#ColorspaceTypeRGBColorspace  + Image.html#mattematte 
Enumerations.html#ColorspaceTypeCMYKColorspace 
red
Quantum
Red
Red
Cyan
green
Quantum
Green
Green
Magenta
blue
Quantum
Blue
Blue
Yellow
opacity
Quantum
Ignored
Opacity
Black
