C# Class ImageTools.IO.Gif.GifDecoder

Decodes GIF files from stream.
Inheritance: IImageDecoder
Show file Open project: prepare/HTML-Renderer Class Usage Examples

Public Methods

Method Description
Decode ( ExtendedImage image, Stream stream ) : void

Decodes the image from the specified stream and sets the data to image.

IsSupportedFileExtension ( string extension ) : bool

Indicates if the image decoder supports the specified file extension.

IsSupportedFileFormat ( byte header ) : bool

Indicates if the image decoder supports the specified file header.

Private Methods

Method Description
ReadComments ( ) : void
ReadFrame ( ) : void
ReadFrameColors ( byte indices, byte colorTable, GifImageDescriptor descriptor ) : void
ReadFrameIndices ( GifImageDescriptor imageDescriptor ) : byte[]
ReadFrameLocalColorTable ( GifImageDescriptor imageDescriptor ) : byte[]
ReadGraphicalControlExtension ( ) : void
ReadImageDescriptor ( ) : GifImageDescriptor
ReadLogicalScreenDescriptor ( ) : void
Skip ( int length ) : void

Method Details

Decode() public method

Decodes the image from the specified stream and sets the data to image.
/// is null (Nothing in Visual Basic). /// - or - /// is null (Nothing in Visual Basic). ///
public Decode ( ExtendedImage image, Stream stream ) : void
image ExtendedImage The image, where the data should be set to. /// Cannot be null (Nothing in Visual Basic).
stream Stream The stream, where the image should be /// decoded from. Cannot be null (Nothing in Visual Basic).
return void

IsSupportedFileExtension() public method

Indicates if the image decoder supports the specified file extension.
/// is null (Nothing in Visual Basic). is a string /// of length zero or contains only blanks.
public IsSupportedFileExtension ( string extension ) : bool
extension string The file extension.
return bool

IsSupportedFileFormat() public method

Indicates if the image decoder supports the specified file header.
/// is null (Nothing in Visual Basic).
public IsSupportedFileFormat ( byte header ) : bool
header byte The file header.
return bool