2.1 KiB
2.1 KiB
ADDED Requirements
Requirement: Ground grid is rendered in the viewport
The system SHALL render a ground plane grid at the Y=0 plane (XZ plane) to provide spatial reference.
Scenario: Grid visible by default
- WHEN the viewport is displaying a scene
- THEN a grid is drawn on the Y=0 plane with lines at regular intervals
Scenario: Grid can be toggled off
- WHEN the user toggles the grid display off via the viewport context menu
- THEN the grid is no longer rendered
Requirement: Axis gizmo is rendered in the viewport corner
The system SHALL render a 3D axis indicator (RGB for XYZ) in the lower-left corner of the viewport to show scene orientation.
Scenario: Axis gizmo visible
- WHEN the viewport is displaying a scene
- THEN an axis gizmo is drawn in the lower-left corner with X=red, Y=green, Z=blue lines and labels
Scenario: Axis gizmo reflects camera orientation
- WHEN the camera is rotated
- THEN the axis gizmo orientation updates to reflect the current view direction
Requirement: Viewport background color is configurable
The system SHALL render the viewport background with a configurable color, defaulting to a dark gray (0.15, 0.15, 0.15).
Scenario: Default background color
- WHEN the viewport is rendered
- THEN the background is cleared to dark gray (0.15, 0.15, 0.15)
Scenario: Background color changed via context menu
- WHEN the user selects a different background color from the viewport settings
- THEN the viewport background is updated to the selected color
Requirement: Viewport context menu provides display options
The system SHALL provide a right-click context menu in the viewport with toggles for grid display and background color options.
Scenario: Right-click opens context menu
- WHEN the user right-clicks within the viewport area
- THEN a context menu appears with options: "Show Grid" (toggle), and "Background" submenu with color presets
Scenario: Toggle grid from context menu
- WHEN the user clicks "Show Grid" in the context menu
- THEN the grid display is toggled on or off