C# Class System.IO.BitSplitter

Splits a byte array into values, based on a series of bit lengths Translations are done from network byte order.
Afficher le fichier Open project: i-e-b/HLS---Smooth-Encoder Class Usage Examples

Protected Properties

Свойство Type Description
offset long
src byte[]

Méthodes publiques

Méthode Description
AlignToByte ( ) : void

Move to the next byte edge (no action if already on one -- moves between 0 and 7 bits)

BitSplitter ( byte RawData ) : System
GetFlag ( ) : bool

Read a single bit, and return true if set to '1'. Advances position by 1 bit

GetInteger ( int BitLength ) : ulong

Return an unsigned long for the integer bits

RemainingBytes ( ) : byte[]

Return a new array containing all remaining whole bytes not consumed.

SkipBits ( int BitCount ) : void

Move forward a given number of bits. They are consumed but not processed.

SkipBytes ( int ByteCount ) : void

Move forward a given number of bytes. They are consumed but not processed.

SkipToNextByte ( ) : void

Move forward to next byte edge (moves between 1 and 8 bits)

Méthodes protégées

Méthode Description
GetNext ( int l ) : byte[]

Get an unshifted array of bits packed in bytes. Advances position counter.

Mask ( int start, int length ) : byte[]

Create a byte mask

Method Details

AlignToByte() public méthode

Move to the next byte edge (no action if already on one -- moves between 0 and 7 bits)
public AlignToByte ( ) : void
Résultat void

BitSplitter() public méthode

public BitSplitter ( byte RawData ) : System
RawData byte
Résultat System

GetFlag() public méthode

Read a single bit, and return true if set to '1'. Advances position by 1 bit
public GetFlag ( ) : bool
Résultat bool

GetInteger() public méthode

Return an unsigned long for the integer bits
public GetInteger ( int BitLength ) : ulong
BitLength int
Résultat ulong

GetNext() protected méthode

Get an unshifted array of bits packed in bytes. Advances position counter.
protected GetNext ( int l ) : byte[]
l int
Résultat byte[]

Mask() protected méthode

Create a byte mask
protected Mask ( int start, int length ) : byte[]
start int number of bits skipped
length int run length (bits)
Résultat byte[]

RemainingBytes() public méthode

Return a new array containing all remaining whole bytes not consumed.
public RemainingBytes ( ) : byte[]
Résultat byte[]

SkipBits() public méthode

Move forward a given number of bits. They are consumed but not processed.
public SkipBits ( int BitCount ) : void
BitCount int
Résultat void

SkipBytes() public méthode

Move forward a given number of bytes. They are consumed but not processed.
public SkipBytes ( int ByteCount ) : void
ByteCount int
Résultat void

SkipToNextByte() public méthode

Move forward to next byte edge (moves between 1 and 8 bits)
public SkipToNextByte ( ) : void
Résultat void

Property Details

offset protected_oe property

protected long offset
Résultat long

src protected_oe property

protected byte[] src
Résultat byte[]