EnvironmentRenderer
Headless renderer for generating environment images without Swing components. Suitable for server-side rendering via gRPC.
Attributes
- Graph
-
- Supertypes
- Self type
-
EnvironmentRenderer.type
Members list
Value members
Concrete methods
Renders environment and encodes as PNG bytes.
Renders environment and encodes as PNG bytes.
Value parameters
- env
-
Environment to render
- height
-
Image height
- width
-
Image width
Attributes
- Returns
-
PNG-encoded byte array
Inherited methods
Calculates viewport transformation for centering and scaling.
Calculates viewport transformation for centering and scaling.
Value parameters
- env
-
The environment to fit in the viewport
- height
-
Target height in pixels
- width
-
Target width in pixels
Attributes
- Returns
-
Viewport configuration
- Inherited from:
- EnvironmentDrawing
Draws all robots in the environment.
Draws all robots in the environment.
Value parameters
- env
-
Environment containing robots
- g
-
Graphics context
- selectedId
-
Optional ID of the selected robot
- vp
-
Viewport configuration
Attributes
- Inherited from:
- EnvironmentDrawing
Draws a single robot with body, direction indicator, and sensors.
Draws a single robot with body, direction indicator, and sensors.
Value parameters
- env
-
Environment for sensor calculations
- g
-
Graphics context
- robot
-
The robot to draw
- selectedId
-
Optional ID of the selected robot
- vp
-
Viewport configuration
Attributes
- Inherited from:
- EnvironmentDrawing
Draws the robot's circular body with gradient and border.
Draws the robot's circular body with gradient and border.
Value parameters
- g
-
Graphics context
- isSelected
-
True if this robot is currently selected
- radius
-
Radius of the robot
- robot
-
The robot to draw
- vp
-
Viewport configuration
Attributes
- Inherited from:
- EnvironmentDrawing
Draws an arrow indicating the robot's orientation.
Draws an arrow indicating the robot's orientation.
Value parameters
- g
-
Graphics context
- radius
-
Radius of the robot
- robot
-
The robot to draw
- vp
-
Viewport configuration
Attributes
- Inherited from:
- EnvironmentDrawing
Draws the coordinate grid.
Draws the coordinate grid.
Value parameters
- env
-
Environment for dimensions
- g
-
Graphics context
- vp
-
Viewport configuration
Attributes
- Inherited from:
- EnvironmentDrawing
Draws coordinate labels with adaptive stepping.
Draws coordinate labels with adaptive stepping.
Value parameters
- env
-
Environment for dimensions
- g
-
Graphics context
- vp
-
Viewport configuration
Attributes
- Inherited from:
- EnvironmentDrawing
Draws sensor detection lines for a robot.
Draws sensor detection lines for a robot.
Value parameters
- env
-
Environment for sensor readings
- g
-
Graphics context
- radius
-
Radius of the robot
- robot
-
The robot whose sensors to draw
- vp
-
Viewport configuration
Attributes
- Inherited from:
- EnvironmentDrawing
Draws all static entities (obstacles and lights).
Draws all static entities (obstacles and lights).
Value parameters
- env
-
Environment containing entities
- g
-
Graphics context
- vp
-
Viewport configuration
Attributes
- Inherited from:
- EnvironmentDrawing