API Reference

Auto-generated from the engine's TypeScript source on 2026-05-21. Run task gen:api-reference to refresh. The hand-curated end-user reference is at Effects.

The complete public API of the OpticScript JavaScript engine, split across four pages so each one stays browsable:

  • Image APIImageHandle (~80 methods covering color, filters, geometry, composition, SVG, pixel access) plus the global Engine factory (loadImage, createCanvas, tool, timer, …).
  • Pixel — RGBA color value with HSL / hex / CSS named-color conversions and the closestName() perceptual reverse lookup.
  • CoordinatesPx / UV types and the px() / uv() factory functions.
  • Types & EnumsBlendMode, Interp, BorderMode, AlphaMode, WarpBorder, plus the shared type aliases (Color, PadColor, Rect).
  • Matrix toolboxMat3 / Mat4 / Vec* / Quat (gl-matrix), the Matrix global. Mat3.estimate* fits transforms to point pairs for warpPerspective.

Looking for end-user effect docs?

The Effects Reference is a hand-curated, bilingual companion to this page — same operations, but grouped by "what-it-does-for-you" instead of by class, with German labels and Wikipedia background links. Use that one if you're trying to figure out which operation gives you the look you want; use this one if you're calling the API from a script.