flushJointsUpload method

void flushJointsUpload()

Uploads the matrices the last getJointsTexture computed, if they are not uploaded yet. On Vulkan an upload is a synchronous submit that waits for the GPU backlog, so the scene runs it only for frames that draw.

Implementation

void flushJointsUpload() {
  if (!_uploadPending) return;
  _uploadPending = false;
  _jointsTextureRing[_jointsTextureRingCursor]!.overwrite(
    _jointMatrixFloats!.buffer.asByteData(),
  );
}