Polarith AI
1.8
AIMContextIndicator Class Reference

Description

The purpose of AIMContextIndicator is to display the objective values during runtime.

In contrast to the AIMContext indicator that uses Unity gizmos, this component uses a shader-based visualization. That makes it applicable even in build mode as long as the target platform supports geometry shaders.

It is possible and often advisable to attach more than one instance of this class to see the combined effect of multiple objectives. A lot of parameters can be adjusted to retain the overview of multiple visualizations, like different IndicatorTypes, the Scale or the SplatShape.

Note, to ensure that the component is functional in build mode, include the Splat shader and the Extrude shader to the "always included shaders" list in the projects Graphics settings.

Inheritance diagram for AIMContextIndicator:

Properties

int TargetObjective [get, set]
 Specifies the objective that is displayed. More...
 
bool DisplayDecision [get, set]
 If true, the decision of the current AI update is displayed. More...
 
bool FilterConstraint [get, set]
 If true, all directions that violate the constraint in at least one objective are not displayed. More...
 
bool AutoShapeScale [get, set]
 If true, the ShapeScale is calculated automatically based on the Scale and the sensor of the attached AIMContext. More...
 
float ShapeScale [get, set]
 Determines the size of the primitive used for displaying an objective value. More...
 
float Scale [get, set]
 The size of the overall visualization for the TargetObjective. More...
 
bool Transparent [get, set]
 If true, the current objective value is passed to the alpha channel. More...
 
IndicatorType IndicatorType [get, set]
 Defines the style of the visualization. More...
 
SplatType SplatShape [get, set]
 Defines the shape of the splats when IndicatorType is set to IndicatorType.Splat. More...
 
float BarLength [get, set]
 The length of a bar if the objective value is 1. More...
 
Color DecisionColor [get, set]
 Is assigned to the receptor with the best possible solution for the current AI update. More...
 
Color InterpolatedDecisionColor [get, set]
 The color of the extra shape that is rendered for the AIMContext.DecidedDirection. More...
 
Color [] ObjectiveColors [get, set]
 The colors that are applied to the different objective value representations. More...
 

Public Methods

void BuildMesh ()
 Guess what, it builds the mesh based on class fields, Captain Obvious strikes again. More...
 
Imprint