Gst.Buffer.prototype.peek_memory

function peek_memory(idx:Number):Gst.Memory {
    // Gjs wrapper for gst_buffer_peek_memory()
}

Get the memory block at idx in buffer. The memory block stays valid until the memory block in buffer is removed, replaced or merged, typically with any call that modifies the memory in buffer.

Since this call does not influence the refcount of the memory, gst_memory_is_writable() can be used to check if buffer is the sole owner of the returned memory.

idx

an index

Returns

the Gst.Memory at idx.