Module

x/canvas/types.ts

Canvas API for Deno, ported from canvaskit-wasm (Skia).
Go to Latest
interface SkPictureRecorder
implements EmbindObject<SkPicture>
import { type SkPictureRecorder } from "https://deno.land/x/canvas@v1.0.0/types.ts";

Methods

beginRecording(bounds: InputRect): SkCanvas

Returns a canvas on which to draw. When done drawing, call finishRecordingAsPicture()

finishRecordingAsPicture(): SkPicture

Returns the captured draw commands as a picture and invalidates the canvas returned earlier.