Skip to content

ITextStudioRenderer

InterfaceTextStudioTextStudio
public interface ITextStudioRenderer

Renderer add-on contract. Components that visualize TextStudio output (extruded 3D text, mechanical flip tiles, custom backends) implement this interface and are auto-detected by the TextStudio.TextStudioText hub.

Drive-all semantics: every enabled renderer receives every frame. Visibility is managed by the user enabling/disabling the component like any other Unity MonoBehaviour - the hub never hides renderers for the user.

void Attach(TextStudioText hub)

Called when the hub binds to this renderer (OnEnable or when added at runtime).

Parameters

Name Type
hub TextStudio.TextStudioText
void Detach()

Called when the hub disconnects (OnDisable, hub removed, component destroyed).

void Render(in TextStudioFrame frame)

Consume one built frame. Called once per pipeline tick on every enabled renderer. Implementations should honor TextStudio.TextStudioFrame.Dirty for incremental writes and TextStudio.TextStudioFrame.GlobalDirty for topology rebuilds. Frame buffers are engine-owned views whose contents may change on a later tick; copy only data that must remain stable after the call.

Parameters

Name Type
frame TextStudio.TextStudioFrame
void OnRevealReset()

Reveal lifecycle hook for renderers with external state (tile schedulers, mesh queues). Called after TextStudio.RevealController.Reset so the renderer can flush any cached per-glyph state before the next tick.

bool IsAvailable { get; }

True when the renderer is fully initialized and ready to consume frames. Returning false skips this renderer for the current tick without logging.

Returns

System.Boolean

RendererCapabilities Capabilities { get; }

What this renderer can express. Most flags are informational; TextStudio.RendererCapabilities.SupportsIdleFrameSkipping allows the hub to skip unchanged frames because the renderer schedules its own asynchronous updates, while TextStudio.RendererCapabilities.ConsumesRawFrameState allows it to reconstruct composed glyph state directly from the frame’s placement and animation arrays.

Returns

TextStudio.RendererCapabilities