Table of Contents

Class DefaultHighlightRenderer

Namespace
Map.Rendering.Highlight
Assembly
MapAssembly.dll

ENGINE: Default GPU compute-based highlight renderer. Provides fill and border-only highlight modes using compute shaders.

public class DefaultHighlightRenderer : HighlightRendererBase, IHighlightRenderer
Inheritance
object
DefaultHighlightRenderer
Implements
Inherited Members

Constructors

DefaultHighlightRenderer(ComputeShader)

public DefaultHighlightRenderer(ComputeShader computeShader = null)

Parameters

computeShader ComputeShader

Properties

DisplayName

Display name for UI/debugging

public override string DisplayName { get; }

Property Value

string

RendererId

Unique identifier for this renderer (e.g., "Default", "Glow", "Pulse")

public override string RendererId { get; }

Property Value

string

RequiresPerFrameUpdate

Whether this renderer requires per-frame updates (e.g., animated effects)

public override bool RequiresPerFrameUpdate { get; }

Property Value

bool

Methods

ApplyToMaterial(Material, HighlightStyleParams)

Apply visual parameters to the material (colors, effects, etc.) Called when visual style parameters change.

public override void ApplyToMaterial(Material material, HighlightStyleParams styleParams)

Parameters

material Material
styleParams HighlightStyleParams

ClearHighlight()

Clear all highlights.

public override void ClearHighlight()

Dispose()

Cleanup resources when renderer is deactivated or destroyed.

public override void Dispose()

HighlightCountry(ushort, Color)

Highlight all provinces owned by a country.

public override void HighlightCountry(ushort countryID, Color color)

Parameters

countryID ushort

Country ID to highlight

color Color

Highlight color with alpha

HighlightProvince(ushort, Color, HighlightMode)

Highlight a single province.

public override void HighlightProvince(ushort provinceID, Color color, HighlightMode mode)

Parameters

provinceID ushort

Province to highlight (0 = clear)

color Color

Highlight color with alpha

mode HighlightMode

Fill or border-only mode

OnInitialize()

Override for custom initialization logic. Called after textureManager and context are set.

protected override void OnInitialize()

SetBorderThickness(float)

Set border thickness for BorderOnly mode.

public void SetBorderThickness(float thickness)

Parameters

thickness float