C# Class SimplePaletteQuantizer.Quantizers.BaseColorCacheQuantizer

Inheritance: BaseColorQuantizer
显示文件 Open project: RHY3756547/FreeSO

Public Methods

Method Description
CachePalette ( IList palette ) : void

Caches the palette.

ChangeCacheProvider ( IColorCache colorCache ) : void

Changes the cache provider.

Protected Methods

Method Description
BaseColorCacheQuantizer ( ) : System

Initializes a new instance of the BaseColorCacheQuantizer class.

OnCreateDefaultCache ( ) : IColorCache

Called when it is needed to create default cache (no cache is supplied from outside).

OnGetPalette ( Int32 colorCount ) : List

See BaseColorQuantizer.OnGetPalette for more details.

OnGetPaletteIndex ( Color color, Int32 key, Int32 x, Int32 y, int &paletteIndex ) : void

See BaseColorQuantizer.OnGetPaletteIndex for more details.

OnGetPaletteToCache ( Int32 colorCount ) : List

Redirection to retrieve palette to be cached, if palette is not available yet.

OnPrepare ( ImageBuffer image ) : void

See BaseColorQuantizer.OnPrepare for more details.

Private Methods

Method Description
GetColorCache ( ) : IColorCache

Method Details

BaseColorCacheQuantizer() protected method

Initializes a new instance of the BaseColorCacheQuantizer class.
protected BaseColorCacheQuantizer ( ) : System
return System

CachePalette() public method

Caches the palette.
public CachePalette ( IList palette ) : void
palette IList The palette.
return void

ChangeCacheProvider() public method

Changes the cache provider.
public ChangeCacheProvider ( IColorCache colorCache ) : void
colorCache IColorCache The color cache.
return void

OnCreateDefaultCache() protected abstract method

Called when it is needed to create default cache (no cache is supplied from outside).
protected abstract OnCreateDefaultCache ( ) : IColorCache
return IColorCache

OnGetPalette() protected final method

See BaseColorQuantizer.OnGetPalette for more details.
protected final OnGetPalette ( Int32 colorCount ) : List
colorCount System.Int32
return List

OnGetPaletteIndex() protected method

See BaseColorQuantizer.OnGetPaletteIndex for more details.
protected OnGetPaletteIndex ( Color color, Int32 key, Int32 x, Int32 y, int &paletteIndex ) : void
color Color
key System.Int32
x System.Int32
y System.Int32
paletteIndex int
return void

OnGetPaletteToCache() protected abstract method

Redirection to retrieve palette to be cached, if palette is not available yet.
protected abstract OnGetPaletteToCache ( Int32 colorCount ) : List
colorCount System.Int32
return List

OnPrepare() protected method

See BaseColorQuantizer.OnPrepare for more details.
protected OnPrepare ( ImageBuffer image ) : void
image SimplePaletteQuantizer.Helpers.ImageBuffer
return void