LedTextBasedDataSource
public abstract class LedTextBasedDataSource : LedDataSourceBase, ILedSource, ITextBlinkSourceCommon base for text-based data source components that share appearance, font and scrolling settings. Derive from this instead of LEDStudio.LedDataSourceBase for any source backed by a LEDStudio.ITextStyledSource.
Fields
Section titled “Fields”
_textColor
Section titled “_textColor”protected Color _textColorReturns
UnityEngine.Color
_backgroundColor
Section titled “_backgroundColor”protected Color _backgroundColorReturns
UnityEngine.Color
_fontAsset
Section titled “_fontAsset”protected TMP_FontAsset _fontAssetReturns
TMPro.TMP_FontAsset
_textSettings
Section titled “_textSettings”protected LedTextSettings _textSettingsReturns
LEDStudio.LedTextSettings
_textRenderBackendAsset
Section titled “_textRenderBackendAsset”protected LedTextRenderBackendAsset _textRenderBackendAssetReturns
LEDStudio.LedTextRenderBackendAsset
_autoScroll
Section titled “_autoScroll”protected bool _autoScrollReturns
System.Boolean
_alwaysScroll
Section titled “_alwaysScroll”protected bool _alwaysScrollReturns
System.Boolean
_seamlessWrap
Section titled “_seamlessWrap”protected bool _seamlessWrapReturns
System.Boolean
_seamlessWrapPaddingPixels
Section titled “_seamlessWrapPaddingPixels”protected float _seamlessWrapPaddingPixelsReturns
System.Single
_seamlessWrapDistribution
Section titled “_seamlessWrapDistribution”protected LedSeamlessWrapDistribution _seamlessWrapDistributionReturns
LEDStudio.LedSeamlessWrapDistribution
_scrollAxis
Section titled “_scrollAxis”protected LedTextScrollAxis _scrollAxisReturns
LEDStudio.LedTextScrollAxis
_scrollSpeed
Section titled “_scrollSpeed”protected float _scrollSpeedReturns
System.Single
_enableScrollOffset
Section titled “_enableScrollOffset”protected bool _enableScrollOffsetReturns
System.Boolean
_scrollOffsetPercent
Section titled “_scrollOffsetPercent”protected float _scrollOffsetPercentReturns
System.Single
_blinkSettings
Section titled “_blinkSettings”protected LedTextBlinkSettings _blinkSettingsReturns
LEDStudio.LedTextBlinkSettings
Methods
Section titled “Methods”
CreateSource(Vector2Int)
Section titled “CreateSource(Vector2Int)”protected abstract void CreateSource(Vector2Int targetResolution)Create the concrete source. Called from LEDStudio.LedTextBasedDataSource.Prepare(UnityEngine.Vector2Int).
Parameters
| Name | Type |
|---|---|
targetResolution |
UnityEngine.Vector2Int |
UpdateSubclassProperties()
Section titled “UpdateSubclassProperties()”protected abstract void UpdateSubclassProperties()Push subclass-specific inspector changes during LEDStudio.LedTextBasedDataSource.UpdateSource(ImpossibleRobert.Common.Timing.TimeStep%40).
PushSubclassProperties()
Section titled “PushSubclassProperties()”protected abstract void PushSubclassProperties()Push all subclass-specific fields to the source (called from LEDStudio.LedTextBasedDataSource.OnValidate).
ReleaseSource()
Section titled “ReleaseSource()”protected abstract void ReleaseSource()Null out the concrete source reference (called from LEDStudio.LedTextBasedDataSource.Release).
BuildTextSettings()
Section titled “BuildTextSettings()”protected LedTextSettings BuildTextSettings()Builds normalized layout settings for the current text source.
Returns
LEDStudio.LedTextSettings
ConfigureTextStyle(Color?, LedTextSettings?, TMP_FontAsset, Color?, bool, bool, bool, float, LedSeamlessWrapDistribution, LedTextScrollAxis, float, bool, float, LedTextBlinkSettings?)
Section titled “ConfigureTextStyle(Color?, LedTextSettings?, TMP_FontAsset, Color?, bool, bool, bool, float, LedSeamlessWrapDistribution, LedTextScrollAxis, float, bool, float, LedTextBlinkSettings?)”public void ConfigureTextStyle(Color? textColor = null, LedTextSettings? textSettings = null, TMP_FontAsset fontAsset = null, Color? backgroundColor = null, bool autoScroll = false, bool alwaysScroll = false, bool seamlessWrap = false, float seamlessWrapPaddingPixels = 8, LedSeamlessWrapDistribution seamlessWrapDistribution = LedSeamlessWrapDistribution.SingleRepeat, LedTextScrollAxis scrollAxis = LedTextScrollAxis.Horizontal, float scrollSpeed = 30, bool enableScrollOffset = false, float scrollOffsetPercent = 0, LedTextBlinkSettings? blinkSettings = null)Replaces the source’s text appearance, scrolling, offset, and blinking configuration, then refreshes the owning board.
Parameters
| Name | Type | Description |
|---|---|---|
textColor |
System.Nullable{UnityEngine.Color} | Foreground color, or null for white. |
textSettings |
System.Nullable{LEDStudio.LedTextSettings} | Text layout and renderer settings, or null for LED Studio defaults. |
fontAsset |
TMPro.TMP_FontAsset | Optional TextMesh Pro font used by font-backed rendering modes. |
backgroundColor |
System.Nullable{UnityEngine.Color} | Background color, or null for transparent. |
autoScroll |
System.Boolean | Whether overflowing content starts scrolling automatically. |
alwaysScroll |
System.Boolean | Whether content scrolls even when it already fits. |
seamlessWrap |
System.Boolean | Whether repeated content crosses the wrap boundary without a blank reset. |
seamlessWrapPaddingPixels |
System.Single | Gap between repeated copies in source pixels. |
seamlessWrapDistribution |
LEDStudio.LedSeamlessWrapDistribution | How repeated copies are distributed across the scroll cycle. |
scrollAxis |
LEDStudio.LedTextScrollAxis | Direction along which text moves. |
scrollSpeed |
System.Single | Signed scroll speed in source pixels per second. |
enableScrollOffset |
System.Boolean | Whether the explicit cycle offset is applied. |
scrollOffsetPercent |
System.Single | Initial position within the scroll cycle, from zero to 100. |
blinkSettings |
System.Nullable{LEDStudio.LedTextBlinkSettings} | Blink timing, or null to disable blinking with default timing. |
Prepare(Vector2Int)
Section titled “Prepare(Vector2Int)”public override sealed void Prepare(Vector2Int targetResolution)Allocates or resizes source resources for the requested logical board resolution.
Parameters
| Name | Type |
|---|---|
targetResolution |
UnityEngine.Vector2Int |
UpdateSource(in TimeStep)
Section titled “UpdateSource(in TimeStep)”public override sealed void UpdateSource(in TimeStep step)Updates time-dependent content using the board’s deterministic simulation step.
Parameters
| Name | Type |
|---|---|
step |
ImpossibleRobert.Common.Timing.TimeStep |
MarkClean()
Section titled “MarkClean()”public override sealed void MarkClean()Clears dirty state after the compositor consumes the current output.
Release()
Section titled “Release()”public override sealed void Release()Releases textures and other resources owned by the source; repeated calls must be safe.
MarkOwningBoardDirty()
Section titled “MarkOwningBoardDirty()”protected void MarkOwningBoardDirty()Invalidates this source and its containing board so style or content changes are rendered on the next update.
Constructors
Section titled “Constructors”
LedTextBasedDataSource()
Section titled “LedTextBasedDataSource()”protected LedTextBasedDataSource()Properties
Section titled “Properties”
StyledSource
Section titled “StyledSource”protected abstract ITextStyledSource StyledSource { get; }The underlying text-styled source created by the subclass.
Returns
LEDStudio.ITextStyledSource
BlinkSettings
Section titled “BlinkSettings”public LedTextBlinkSettings BlinkSettings { get; set; }Returns
LEDStudio.LedTextBlinkSettings
RequiresTimeUpdates
Section titled “RequiresTimeUpdates”public virtual bool RequiresTimeUpdates { get; }Returns
System.Boolean
TextRenderBackendAsset
Section titled “TextRenderBackendAsset”public LedTextRenderBackendAsset TextRenderBackendAsset { get; set; }Returns
LEDStudio.LedTextRenderBackendAsset
ScrollSpeed
Section titled “ScrollSpeed”public float ScrollSpeed { get; set; }Returns
System.Single
IsReady
Section titled “IsReady”public override sealed bool IsReady { get; }Returns
System.Boolean
IsDirty
Section titled “IsDirty”public override sealed bool IsDirty { get; }Returns
System.Boolean
OutputTexture
Section titled “OutputTexture”public override sealed Texture OutputTexture { get; }Returns
UnityEngine.Texture