LedSyncManager
public static class LedSyncManagerManages sync groups across multiple LEDStudio.LedBoardController instances. Boards that belong to the same group share a single monotonic clock and advance together, so playlists, animated sources, and flicker defects remain phase-locked across boards. Boards register/unregister on enable/disable; LEDStudio.LedSyncDriver advances the shared clock once per frame in both play and edit mode.
Methods
Section titled “Methods”
Register(LedBoardController, string)
Section titled “Register(LedBoardController, string)”public static void Register(LedBoardController board, string groupId)Adds a board to a shared clock group, creating the group from that board’s timing settings when necessary.
Parameters
| Name | Type |
|---|---|
board |
LEDStudio.LedBoardController |
groupId |
System.String |
Remarks
Null boards and empty group IDs are ignored. Registering the same board twice has no effect.
Unregister(LedBoardController, string)
Section titled “Unregister(LedBoardController, string)”public static void Unregister(LedBoardController board, string groupId)Removes a board from a shared clock group and deletes the group after its final member leaves.
Parameters
| Name | Type |
|---|---|
board |
LEDStudio.LedBoardController |
groupId |
System.String |
GetGroupTime(string)
Section titled “GetGroupTime(string)”public static double GetGroupTime(string groupId)Returns the shared clock time for a group, or -1 when the group does not exist. Callers treat -1 as “fall back to local clock”.
Parameters
| Name | Type |
|---|---|
groupId |
System.String |
Returns
System.Double
SetGroupTime(string, double)
Section titled “SetGroupTime(string, double)”public static void SetGroupTime(string groupId, double time)Sets an existing group’s shared clock in seconds so all member boards resume from the same instant.
Parameters
| Name | Type |
|---|---|
groupId |
System.String |
time |
System.Double |
Remarks
Unknown or empty group IDs are ignored.
AdvanceGroup(string, float)
Section titled “AdvanceGroup(string, float)”public static void AdvanceGroup(string groupId, float deltaTime)Advances an existing group’s shared clock by a caller-supplied number of seconds.
Parameters
| Name | Type |
|---|---|
groupId |
System.String |
deltaTime |
System.Single |
Remarks
Unknown or empty group IDs are ignored.
AdvanceAll(float)
Section titled “AdvanceAll(float)”public static void AdvanceAll(float deltaTime)Advance every registered group’s clock by the given delta.
Parameters
| Name | Type |
|---|---|
deltaTime |
System.Single |
Clear()
Section titled “Clear()”public static void Clear()Remove all registered groups. Use when reloading a scene from code.
Properties
Section titled “Properties”
GroupIds
Section titled “GroupIds”public static IReadOnlyCollection<string> GroupIds { get; }Currently known group ids (read-only snapshot).
Returns
System.Collections.Generic.IReadOnlyCollection{System.String}