Analysis Dashboard
Reads a JSON payload from Terrain/LEAP analysis tools and renders a responsive Legend HUD.
Overview
Reads a JSON payload from Terrain/LEAP analysis tools and renders a responsive Legend HUD.
Inputs (10)
- Run (Boolean): Enable HUD
- Dashboard Data (Text): JSON string representing the analysis data or legend
- Size (Number): Base text size
- Anchor (Integer): 0=TL, 1=TR, 2=BL, 3=BR
- Font (Text): Font family name
- Font Color (Colour): Text color
- Transparency (Number): HUD background opacity (0-1)
- Offset X (Number): X margin from screen edge
- Offset Y (Number): Y margin from screen edge
- Padding (Number): Padding inside the HUD box
Outputs (0)
- None
Method, assumptions and simplifications
The same notes appear in the component's Info output.
Method
- Parses the Dashboard Data JSON: Type (Discrete, Gradient or Blocks, default Discrete), Title, Colors (R, G, B objects), Labels and Metrics (Name, Value pairs).
- While Run is True it draws a screen-space HUD in every viewport: a dark box (opacity = Transparency) anchored to a corner with Offset X and Offset Y margins in pixels, the title in capitals, one line per metric and a colour legend with the last colour at the top.
- Legend labels: Discrete shows one label per colour; Blocks with one more label than colours shows ranges between consecutive labels; Gradient shows only the minimum and maximum labels.
- If the upstream component that supplies the data is locked (disabled), the payload is ignored and nothing is drawn.
Assumptions
- The JSON follows the schema written by the Enzyme analysis components (keys are case-sensitive).
Simplifications and limits
- Box width is estimated from character count × 0.65 × Size, so long labels or wide fonts can overflow the box.
- Nothing is drawn when the payload has neither Colors nor Metrics; a payload with Metrics only shows the title and metrics without a legend.
Workflow
- Any analysis component Dashboard Data output -> Dashboard Data. Share one Run toggle with the analysis components.