LSLReusableBuffer<T extends NativeType> constructor
Creates a reusable buffer of the given capacity.
@param capacity The capacity of the buffer in number of elements.
@param buffer The buffer to store the sample.
Implementation
LSLReusableBuffer(this.capacity, this.buffer) {
if (buffer.isNullPointer && (this is! LSLReusableBufferVoid)) {
throw ArgumentError('Error allocating buffer of type ${T.runtimeType}');
}
}