AutoMovie API
    Preparing search index...

    Class AutoMovieDrawSession

    A host's hold on one draw page: the props injected before it loaded, the subject it described, and the calls that turn cells and frames into pictures through its draw function.

    Every picture a host saves comes through draw, drawing or frame, which call the page's draw function and decode what it returns; the session never screenshots the page and injects no style into it. Each call is bounded by the session's timeout, so a subject that never reports ready fails the call with the cell or frame it was drawing instead of holding the host forever. Calls must not overlap.

    const session = await AutoMovieDrawSession.open({ page, url, props: { subject: "starter", props: null }, backend: "swiftshader; Chromium 131", timeout: 120_000 });
    const plan = planAutoMovieCapture({ request, subject: session.subject, cuts: [] });
    await runAutoMovieCapture({ plan, draw: (cell) => session.drawing(cell, plan), folder, revision, match: "cell" });
    await session.close();
    Index
    backend: string

    What every drawn row records as its backend: the host's launch description, then the renderer string.

    renderer: string

    The WebGL renderer string the page reported.

    The subject the page created, as a capture plans against it.

    • Inject the props, load the draw page, wait for its draw function and describe its subject.

      It rejects when the page does not install the draw function within the timeout, naming the address, and when describing the subject fails or outlasts the timeout. A rejected open leaves the page with the caller.

      Parameters

      • props: {
            backend: string;
            page: IAutoMovieDrawPage;
            props: IAutoMovieDrawProps;
            timeout: number;
            url: string;
        }
        • backend: string

          The host's description of how the browser draws, such as swiftshader; Chromium 131.0.6778.33.

        • page: IAutoMovieDrawPage

          A fresh page, which the session owns once open resolves.

        • props: IAutoMovieDrawProps

          What the page's draw function creates.

        • timeout: number

          Milliseconds any one page call may take.

        • url: string

          Address of the draw page.

      Returns Promise<AutoMovieDrawSession>