getChunk

open fun getChunk(index: Int, info: MediaCodec.BufferInfo): ByteBuffer

Returns a reference to a "direct" ByteBuffer with the data, and fills in the BufferInfo.

The caller must not modify the contents of the returned ByteBuffer. Altering the position and limit is allowed.