Method | Description | |
---|---|---|
OctreeQuantizer ( int maxColors, int maxColorBits ) : System |
Construct the octree quantizer The Octree quantizer is a two pass algorithm. The initial pass sets up the octree, the second pass quantizes a color based on the nodes in the tree |
Method | Description | |
---|---|---|
GetPalette ( System.Drawing.Imaging.ColorPalette original ) : System.Drawing.Imaging.ColorPalette |
Retrieve the palette for the quantized image
|
|
InitialQuantizePixel ( Color32 pixel ) : void |
Process the pixel in the first pass of the algorithm This function need only be overridden if your quantize algorithm needs two passes, such as an Octree quantizer. |
|
QuantizePixel ( Color32 pixel ) : byte |
Override this to process the pixel in the second pass of the algorithm
|
protected GetPalette ( System.Drawing.Imaging.ColorPalette original ) : System.Drawing.Imaging.ColorPalette | ||
original | System.Drawing.Imaging.ColorPalette | Any old palette, this is overrwritten |
return | System.Drawing.Imaging.ColorPalette |
protected InitialQuantizePixel ( Color32 pixel ) : void | ||
pixel | Color32 | The pixel to quantize |
return | void |
public OctreeQuantizer ( int maxColors, int maxColorBits ) : System | ||
maxColors | int | The maximum number of colors to return |
maxColorBits | int | The number of significant bits |
return | System |
protected QuantizePixel ( Color32 pixel ) : byte | ||
pixel | Color32 | The pixel to quantize |
return | byte |