API Reference
Auto-generated from the engine's TypeScript source on 2026-05-21. Run
task gen:api-referenceto 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 API —
ImageHandle(~80 methods covering color, filters, geometry, composition, SVG, pixel access) plus the globalEnginefactory (loadImage,createCanvas,tool,timer, …). - Pixel — RGBA color value with HSL / hex / CSS
named-color conversions and the
closestName()perceptual reverse lookup. - Coordinates —
Px/UVtypes and thepx()/uv()factory functions. - Types & Enums —
BlendMode,Interp,BorderMode,AlphaMode,WarpBorder, plus the shared type aliases (Color,PadColor,Rect). - Matrix toolbox —
Mat3/Mat4/Vec*/Quat(gl-matrix), theMatrixglobal.Mat3.estimate*fits transforms to point pairs forwarpPerspective.
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.