ecspresso
    Preparing search index...
    • Convert a DOM pointer event's client coordinates to design-resolution (logical) coordinates. Handles canvas offset, CSS-pixel to physical-pixel scaling, and viewport letterbox/crop offsets. Suitable for wiring into the input plugin's coordinateTransform option.

      Parameters

      • clientX: number
      • clientY: number
      • canvas: HTMLCanvasElement
      • viewport: ViewportScale

      Returns { x: number; y: number }