Class RangeDefaultVisualizer
Default visualizer for sensor_msgs/Range messages. Draws a cone representing the sensor field-of-view and current range measurement.
Inheritance
Inherited Members
Namespace: Global Namespace
Assembly: Unity.SimulationPro.Foundation.Visualizations.dll
Syntax
public class RangeDefaultVisualizer : DrawingVisualizer<RangeMsg>, IVisualFactory, IPriority
Methods
CreateGUI(RangeMsg, MessageMetadata)
Creates a GUI callback that renders an Inspector panel for the message data.
Declaration
public override Action CreateGUI(RangeMsg message, MessageMetadata meta)
Parameters
| Type | Name | Description |
|---|---|---|
| RangeMsg | message | The message data to visualize. |
| MessageMetadata | meta | Metadata about the received message (topic, timestamp, frame). |
Returns
| Type | Description |
|---|---|
| Action | An action that draws the GUI. |
Overrides
Draw(Drawing3d, RangeMsg, MessageMetadata)
Draws a 3D visualization of the message data.
Declaration
public override void Draw(Drawing3d drawing, RangeMsg message, MessageMetadata meta)
Parameters
| Type | Name | Description |
|---|---|---|
| Drawing3d | drawing | The 3D drawing context to render into. |
| RangeMsg | message | The message data to visualize. |
| MessageMetadata | meta | Metadata about the received message (topic, timestamp, frame). |
Overrides
Draw<C>(RangeMsg, Drawing3d, Color, float, bool)
Draws a cone representing the sensor's field-of-view and the current range value, with color mapped by the range within [min_range, max_range].
Declaration
public static void Draw<C>(RangeMsg message, Drawing3d drawing, Color color, float size = 0.1, bool drawUnityAxes = false) where C : ICoordinateSpace, new()
Parameters
| Type | Name | Description |
|---|---|---|
| RangeMsg | message | The message data to visualize. |
| Drawing3d | drawing | The Drawing3d to draw into. |
| Color | color | Unused; the cone color is determined by the normalized range value. |
| float | size | Unused; reserved for future use. |
| bool | drawUnityAxes | Unused; reserved for future use. |
Type Parameters
| Name | Description |
|---|---|
| C | The coordinate space of the range data. |