C# Class AlbLib.IFF.IFFReader

Class used when reading files in IFF format.
Afficher le fichier Open project: IllidanS4/AlbLib Class Usage Examples

Méthodes publiques

Méthode Description
IFFReader ( Stream input ) : System

Initializes new instance using stream.

ReadAll ( ) : IEnumerable

Enumerates through all chunks in file.

ReadByte ( ) : byte

Reads one byte.

ReadBytes ( int count ) : byte[]

Reads bytes with specified count.

ReadChunkHeader ( ) : IFFChunk

Reads chunk header.

ReadFileHeader ( ) : IFFFile

Reads file header on beginning of data.

ReadInt16 ( ) : short

Reads one int16. Automatically converted to little endian.

ReadInt32 ( ) : int

Reads one int32. Automatically converted to little endian.

ReadRest ( ) : void

Reads all remaining bytes from chunk.

ReadUInt16 ( ) : ushort

Reads one uint16. Automatically converted to little endian.

ReadUInt32 ( ) : uint

Reads one uint32. Automatically converted to little endian.

ReadUnpack ( int count ) : byte[]

Reads packed bytes with specified count.

ToLittleEndian ( int value ) : int

Converts value in big endian to current endian.

ToLittleEndian ( short value ) : short

Converts value in big endian to current endian.

ToLittleEndian ( uint value ) : uint

Converts value in big endian to current endian.

ToLittleEndian ( ushort value ) : ushort

Converts value in big endian to current endian.

Unpack ( Stream input, int size, int &read ) : byte[]

Reads packed data from stream.

Unpack ( Stream input, Stream output, int size ) : int

Reads packed data from stream.

Method Details

IFFReader() public méthode

Initializes new instance using stream.
public IFFReader ( Stream input ) : System
input Stream /// Input stream. ///
Résultat System

ReadAll() public méthode

Enumerates through all chunks in file.
public ReadAll ( ) : IEnumerable
Résultat IEnumerable

ReadByte() public méthode

Reads one byte.
public ReadByte ( ) : byte
Résultat byte

ReadBytes() public méthode

Reads bytes with specified count.
public ReadBytes ( int count ) : byte[]
count int /// Bytes count. ///
Résultat byte[]

ReadChunkHeader() public méthode

Reads chunk header.
public ReadChunkHeader ( ) : IFFChunk
Résultat IFFChunk

ReadFileHeader() public méthode

Reads file header on beginning of data.
public ReadFileHeader ( ) : IFFFile
Résultat IFFFile

ReadInt16() public méthode

Reads one int16. Automatically converted to little endian.
public ReadInt16 ( ) : short
Résultat short

ReadInt32() public méthode

Reads one int32. Automatically converted to little endian.
public ReadInt32 ( ) : int
Résultat int

ReadRest() public méthode

Reads all remaining bytes from chunk.
public ReadRest ( ) : void
Résultat void

ReadUInt16() public méthode

Reads one uint16. Automatically converted to little endian.
public ReadUInt16 ( ) : ushort
Résultat ushort

ReadUInt32() public méthode

Reads one uint32. Automatically converted to little endian.
public ReadUInt32 ( ) : uint
Résultat uint

ReadUnpack() public méthode

Reads packed bytes with specified count.
public ReadUnpack ( int count ) : byte[]
count int /// Bytes count. ///
Résultat byte[]

ToLittleEndian() public static méthode

Converts value in big endian to current endian.
public static ToLittleEndian ( int value ) : int
value int /// Value to convert. ///
Résultat int

ToLittleEndian() public static méthode

Converts value in big endian to current endian.
public static ToLittleEndian ( short value ) : short
value short /// Value to convert. ///
Résultat short

ToLittleEndian() public static méthode

Converts value in big endian to current endian.
public static ToLittleEndian ( uint value ) : uint
value uint /// Value to convert. ///
Résultat uint

ToLittleEndian() public static méthode

Converts value in big endian to current endian.
public static ToLittleEndian ( ushort value ) : ushort
value ushort /// Value to convert. ///
Résultat ushort

Unpack() public static méthode

Reads packed data from stream.
public static Unpack ( Stream input, int size, int &read ) : byte[]
input Stream /// Input stream. ///
size int /// Data size. ///
read int /// Bytes read. ///
Résultat byte[]

Unpack() public static méthode

Reads packed data from stream.
public static Unpack ( Stream input, Stream output, int size ) : int
input Stream /// Input stream. ///
output Stream /// Output stream. ///
size int /// Data size. ///
Résultat int