mapAsync method

JSPromise<JSAny?> mapAsync(
  1. int mode, [
  2. int offset,
  3. int size
])

Maps a range for reading or writing, which is how a readback gets at its staging buffer.

offset and size are bytes here, unlike writeBuffer's. Omitted, the whole buffer is mapped.

Implementation

external JSPromise<JSAny?> mapAsync(int mode, [int offset, int size]);