-
Notifications
You must be signed in to change notification settings - Fork 146
Stream Class Reference
The AV.Stream
class represents a stream of binary data backed by a BufferList. Stream
s handle the complexity of reading various types of values from a binary data stream for you, including issues regarding the native endianness of the platform. Stream
s are one of the most common pieces of code you will use when writing Aurora decoders.
- copy
- available
- remainingBytes
- advance
- rewind
- seek
- readUInt8
- peekUInt8
- readInt8
- peekInt8
- readUInt16
- peekUInt16
- readInt16
- peekInt16
- readUInt24
- peekUInt24
- readInt24
- peekInt24
- readUInt32
- peekUInt32
- readInt32
- peekInt32
- readFloat32
- peekFloat32
- readFloat64
- peekFloat64
- readFloat80
- peekFloat80
- readString
- peekString
- readBuffer
- peekBuffer
- readSingleBuffer
- peekSingleBuffer
Creates a new AV.Stream
with the specified AV.BufferList
.
Returns a new AV.Stream
with a new AV.BufferList
containing the specified buffer.
The current byte offset in the stream.
Returns a new AV.Stream
backed by the same data at the same offset.
Returns whether the stream has the specified number of bytes available as a boolean.
Returns the number of remaining bytes in the stream.
Advances the current offset
of the stream by the specified number of bytes, advancing the buffer list as necessary.
Rewinds the current offset
of the stream by the specified number of bytes, rewinding the buffer list as necessary.
Advances or rewinds the stream so that the offset
is equal to the given position
, updating the buffer list as necessary.
Returns an unsigned 8 bit integer at the current offset
and advances offset
.
Returns an unsigned 8 bit integer the specified number of bytes past the current offset
without advancing the current offset
.
Returns a signed 8 bit integer at the current offset
and advances offset
.
Returns a signed 8 bit integer the specified number of bytes past the current offset
without advancing the current offset
.
Returns an unsigned 16 bit integer at the current offset
and advances offset
.
Returns an unsigned 16 bit integer the specified number of bytes past the current offset
without advancing the current offset
.
Returns a signed 16 bit integer at the current offset
and advances offset
.
Returns a signed 16 bit integer the specified number of bytes past the current offset
without advancing the current offset
.
Returns an unsigned 24 bit integer at the current offset
and advances offset
.
Returns an unsigned 24 bit integer the specified number of bytes past the current offset
without advancing the current offset
.
Returns a signed 24 bit integer at the current offset
and advances offset
.
Returns a signed 24 bit integer the specified number of bytes past the current offset
without advancing the current offset
.
Returns an unsigned 32 bit integer at the current offset
and advances offset
.
Returns an unsigned 32 bit integer the specified number of bytes past the current offset
without advancing the current offset
.
Returns a signed 32 bit integer at the current offset
and advances offset
.
Returns a signed 32 bit integer the specified number of bytes past the current offset
without advancing the current offset
.
Returns a 32 bit floating point number at the current offset
and advances offset
.
Returns a 32 bit floating point number the specified number of bytes past the current offset
without advancing the current offset
.
Returns a 64 bit floating point number at the current offset
and advances offset
.
Returns a 64 bit floating point number the specified number of bytes past the current offset
without advancing the current offset
.
Returns an 80 bit extended floating point number at the current offset
and advances offset
.
Returns an 80 bit extended floating point number the specified number of bytes past the current offset
without advancing the current offset
.
Returns a string containing the specified number of ascii characters after the current offset
and advances the current offset
.
Returns a string containing the specified number of ascii characters, starting at the specified number of bytes past the current offset
, without advancing the current offset
.
Returns a new AV.Buffer
containing the specified number of bytes after the current offset
. The string is read in the given encoding, which is 'ascii'
by default. Allowable encodings are 'ascii', 'utf8', 'utf16-be', 'utf16-le', and 'utf16-bom'.
Returns a new AV.Buffer
of the specified length, starting at the specified number of bytes after the current offset
. The string is read in the given encoding, which is 'ascii'
by default. Allowable encodings are 'ascii', 'utf8', 'utf16-be', 'utf16-le', and 'utf16-bom'.
Returns a new AV.Buffer
containing either length
bytes or the number of remaining bytes in the current buffer after the current offset
, whichever is smaller, and advances the current offset
.
Returns a new AV.Buffer
containing either length
bytes or the number of remaining bytes in the current buffer after the current offset
, whichever is smaller, without advancing the current offset
.