Runtime API
Game code should talk to a board through ILedBoardRuntime. LedBoardController implements this interface, so scripts can drive content without depending on internal composition details. The interface also covers board setup, quality, generated topology, board body extrusion, presentation background, live inputs, named runtime ports, emitter count/density changes, and pointer-to-board hit mapping.
using LEDStudio;
using UnityEngine;
public sealed class ScoreboardController : MonoBehaviour
{
[SerializeField] LedBoardController board;
[SerializeField] LedPlaylistAsset gamePlaylist;
[SerializeField] Texture sponsorTexture;
void Start()
{
ILedBoardRuntime runtime = board;
runtime.SetPlaylist(gamePlaylist);
runtime.SetSourceText("headline", "MATCH START");
runtime.SetSourceTexture("sponsor", sponsorTexture);
runtime.SetScore("HOME", "AWAY", "Q1", "12:00");
}
}
Member | Purpose |
SetPlaylist / ResetPlaylistPlayback | Assign or restart timed playlist playback. |
SetSource / SetComposition | Assign a persistent board Source Asset or LED Composition overlay. |
Board setup and sizing | Set profiles or inline board settings, adjust pitch/emitter/cabinet values, change emitter count or density, and map world-space hits back to board coordinates. |
Runtime ports | Create named text, image, render texture, UI Toolkit, timer, score, canvas, video, and custom source ports from code. |
Topology and extrusion | Assign topology assets or inline topology settings, refresh generated meshes, set body extrusion, and set side/back materials. |
Quality, background, and live inputs | Set quality profiles or inline quality, set logical and presentation background colors, and bind or clear reusable live inputs. |
SetSourceText / SetSourceTexture | Update a text or texture source by SourceId. |
SetScore | Push structured scoreboard values. |
MarkSourceDirty | Refresh a manual-update source, optionally limited to a source-texture rectangle. |
ApplyDefectProfile / ClearDefectProfile | Add or remove runtime defect profiles. |
SetDefectSeverity / SetDefectEnabled / DefectsEnabled | Adjust defect intensity, toggle defects, or inspect the defect toggle. |
SetSuspended | Pause or resume board updates while keeping allocated textures alive. |
SetSyncClock / SyncGroupId | Reset or scrub a board or sync group clock and inspect the effective sync group. |
OutputTexture / CurrentComposition | Read the current logical board output texture or active display composition. |
PlaylistIndex / PlaylistTime / LifecycleState | Inspect playlist progress and board lifecycle state. |