window.kaolin
    Preparing search index...

    Function drawBlobToCanvas

    • Draw a Blob onto a canvas element, replacing its current content. Decode errors are logged to the console and leave the canvas unchanged.

      Parameters

      • canvasOrId: CanvasOrId

        Canvas element or its DOM id.

      • blob: Blob

        Image blob to draw (PNG, JPEG, or any format supported by createImageBitmap).

      Returns Promise<void>

      Promise that resolves when drawing is complete or silently on failure.