detect_text_regions
Return the OCR text regions detected in a clip's video frames OR a still image asset. Pass either clip (a video..clip filename) or image (an image layer's filename) — not both. Video clips are sampled every 0.3s at upload time; images are OCR'd once. Results are cached in R2 next to the source. Returns { status: 'ready' | 'not-ready', frames: [{ frame, time, words: [{ text, x0, y0, x1, y1, confidence }] }], videoWidth, videoHeight }. For an image there's a single frame (frame 0); videoWidth/videoHeight are the image's pixel dimensions. Each words entry is one detected text line — text may hold several words, the box is axis-aligned, and confidence is 0–100. Coordinates are in the SOURCE pixel space (not canvas space). Use to know where titles / subtitles / lower-thirds are baked into the video or image so the Morpha title + intro graphics can be positioned to not collide.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| clip | No | Video clip filename (the same value as `video.<id>.clip`). Pass this OR `image`. | |
| image | No | Image layer filename (the same value as `image.<id>.filename`). Pass this OR `clip`. | |
| projectId | Yes | Project the clip/image belongs to. |