BufferAllocReadChannel

final case class BufferAllocReadChannel(id: Int, path: String, startFrame: Int, numFrames: Int, channels: List[Int], completion: Option[Packet]) extends Message with HasCompletion

The /b_allocReadChannel message tells the server to allocate memory for a buffer and read in a portion of an audio-file, selecting a subset of its channels. The number of channels is given by the size of the channels argument, and the sample-rate of the buffer is determined by the audio-file.

The /b_allocReadChannel message tells the server to allocate memory for a buffer and read in a portion of an audio-file, selecting a subset of its channels. The number of channels is given by the size of the channels argument, and the sample-rate of the buffer is determined by the audio-file.

Value Params
channels

a sequence of channel indices to read. Zero corresponds to the first channel of the file.

id

the identifier to use for the buffer. It must denote a currently un-allocated buffer and be greater than or equal to zero and less than the maximum number of buffers.

numFrames

the number of frames to read which will be the size of the allocated buffer. The special value of -1 denotes that the number of frames available in the file from the given offset is used (the entire file will be read).

path

the path of the audio-file to read. Since the server is an independent process, this must resolve with respect to the server's current working directory. If the server is running on a remote node, the path will be resolved in the server's local file system.

startFrame

the offset in frames into the audio-file to begin reading from

See also
trait Serializable
trait Product
trait Equals
trait AsyncSend
trait Send
class Message
trait Packet
class Object
trait Matchable
class Any

Value members

Concrete methods

def updateCompletion(completion: Option[Packet]): BufferAllocReadChannel

Inherited methods

def encode(c: PacketCodec, b: ByteBuffer): Unit
Inherited from
Message
def encodedSize(c: PacketCodec): Int
Inherited from
Message
override def equals(other: Any): Boolean
Definition Classes
Message -> Any
Inherited from
Message
override def hashCode(): Int
Definition Classes
Message -> Any
Inherited from
Message
final def isSynchronous: Boolean
Inherited from
AsyncSend
def productElementNames: Iterator[String]
Inherited from
Product
def productIterator: Iterator[Any]
Inherited from
Product
override def toString: String
Definition Classes
Message -> Any
Inherited from
Message

Inherited fields

val args: Any*
Inherited from
Message
val name: String
Inherited from
Message