ChartMorpher
public class ChartMorpherDrives value and chart-type transitions. Interpolates previous-to-current mark values via a Burst job using an ChartGuru.Animation curve.
Events
Section titled “Events”
OnMorphStarted
Section titled “OnMorphStarted”public event Action<ChartMorpher> OnMorphStartedNo description is available for this member.
Returns
System.Action{ChartGuru.ChartMorpher} — No return description is available.
OnMorphProgress
Section titled “OnMorphProgress”public event Action<ChartMorpher, float> OnMorphProgressNo description is available for this member.
Returns
System.Action{ChartGuru.ChartMorpher,System.Single} — No return description is available.
OnMorphComplete
Section titled “OnMorphComplete”public event Action<ChartMorpher> OnMorphCompleteNo description is available for this member.
Returns
System.Action{ChartGuru.ChartMorpher} — No return description is available.
Properties
Section titled “Properties”
public MorphState State { get; }No description is available for this member.
Returns
ChartGuru.MorphState — No return description is available.
Progress
Section titled “Progress”public float Progress { get; }No description is available for this member.
Returns
System.Single — No return description is available.
EasedProgress
Section titled “EasedProgress”public float EasedProgress { get; }Eased progress in [0, 1] (may briefly overshoot for spring curves). Use for domain/grid animation.
Returns
System.Single — No return description is available.
SourceType
Section titled “SourceType”public ChartType SourceType { get; }No description is available for this member.
Returns
ChartGuru.ChartType — No return description is available.
TargetType
Section titled “TargetType”public ChartType TargetType { get; }No description is available for this member.
Returns
ChartGuru.ChartType — No return description is available.
IsMorphing
Section titled “IsMorphing”public bool IsMorphing { get; }No description is available for this member.
Returns
System.Boolean — No return description is available.
IsTypeMorph
Section titled “IsTypeMorph”public bool IsTypeMorph { get; }True while a chart-type transition is in progress (source and target types differ).
Returns
System.Boolean — No return description is available.
MorphStyle
Section titled “MorphStyle”public ChartMorphStyle MorphStyle { get; }Visual style the renderer should use for the ongoing type morph.
Returns
ChartGuru.ChartMorphStyle — No return description is available.
CurrentPositions
Section titled “CurrentPositions”public NativeArray<float2> CurrentPositions { get; }No description is available for this member.
Returns
Unity.Collections.NativeArray{Unity.Mathematics.float2} — No return description is available.
CurrentValues
Section titled “CurrentValues”public NativeArray<float> CurrentValues { get; }No description is available for this member.
Returns
Unity.Collections.NativeArray{System.Single} — No return description is available.
HasAnimatedColors
Section titled “HasAnimatedColors”public bool HasAnimatedColors { get; }No description is available for this member.
Returns
System.Boolean — No return description is available.
SourceXDomain
Section titled “SourceXDomain”public Vector2 SourceXDomain { get; }No description is available for this member.
Returns
UnityEngine.Vector2 — No return description is available.
SourceYDomain
Section titled “SourceYDomain”public Vector2 SourceYDomain { get; }No description is available for this member.
Returns
UnityEngine.Vector2 — No return description is available.
IsEntryAnimation
Section titled “IsEntryAnimation”public bool IsEntryAnimation { get; }True while the in-progress value animation began with no previous values
(i.e. it was triggered by ChartGuru.Chart.ReplayEntryAnimation(System.Nullable%7bChartGuru.Animation%7d)). Renderers
can use this to opt into kind-specific entry-only motion modifiers (alpha
fade, scale-in, slide-in, color lerp from theme background, …) that would
look strange during ordinary data-change animations.
Returns
System.Boolean — No return description is available.
Constructors
Section titled “Constructors”
ChartMorpher(Chart)
Section titled “ChartMorpher(Chart)”public ChartMorpher(Chart chart)No description is available for this member.
Parameters
| Name | Type | Description |
|---|---|---|
chart |
ChartGuru.Chart |
Methods
Section titled “Methods”
StartMorph(ChartType, ChartType, Animation, Action)
Section titled “StartMorph(ChartType, ChartType, Animation, Action)”public void StartMorph(ChartType sourceType, ChartType targetType, Animation animation, Action onComplete = null)Starts a chart-type morph. The chart has already switched to targetType
by the time this is called. The morpher keeps values stable (source == target) so the
data doesn’t “grow in” on every morph; instead the renderer cross-fades between the
source and target chart type using ChartGuru.ChartMorpher.EasedProgress.
Parameters
| Name | Type | Description |
|---|---|---|
sourceType |
ChartGuru.ChartType | |
targetType |
ChartGuru.ChartType | |
animation |
ChartGuru.Animation | |
onComplete |
System.Action | |
StartMorph(ChartType, ChartType, Animation, ChartMorphStyle, Action)
Section titled “StartMorph(ChartType, ChartType, Animation, ChartMorphStyle, Action)”public void StartMorph(ChartType sourceType, ChartType targetType, Animation animation, ChartMorphStyle style, Action onComplete = null)Starts a chart-type morph. The chart has already switched to targetType
by the time this is called. The morpher keeps values stable (source == target) so the
data doesn’t “grow in” on every morph; instead the renderer cross-fades between the
source and target chart type using ChartGuru.ChartMorpher.EasedProgress.
Parameters
| Name | Type | Description |
|---|---|---|
sourceType |
ChartGuru.ChartType | |
targetType |
ChartGuru.ChartType | |
animation |
ChartGuru.Animation | |
style |
ChartGuru.ChartMorphStyle | |
onComplete |
System.Action | |
StartValueAnimation(float[], Color[], Color[], Animation)
Section titled “StartValueAnimation(float[], Color[], Color[], Animation)”public void StartValueAnimation(float[] previousValues, Color[] previousColors, Color[] currentColors, Animation animation)Starts a value animation from previous values to current values. Used when data changes
and the chart has a non-null ChartGuru.Chart.Animation.
Parameters
| Name | Type | Description |
|---|---|---|
previousValues |
System.Single[] | |
previousColors |
UnityEngine.Color[] | |
currentColors |
UnityEngine.Color[] | |
animation |
ChartGuru.Animation | |
Update(float)
Section titled “Update(float)”public void Update(float deltaTime)No description is available for this member.
Parameters
| Name | Type | Description |
|---|---|---|
deltaTime |
System.Single | |
CompleteMorph()
Section titled “CompleteMorph()”public void CompleteMorph()No description is available for this member.
CancelMorph()
Section titled “CancelMorph()”public void CancelMorph()No description is available for this member.
TryGetCurrentColor(int, out Color)
Section titled “TryGetCurrentColor(int, out Color)”public bool TryGetCurrentColor(int index, out Color color)No description is available for this member.
Parameters
| Name | Type | Description |
|---|---|---|
index |
System.Int32 | |
color |
UnityEngine.Color |
Returns
System.Boolean — No return description is available.
Dispose()
Section titled “Dispose()”public void Dispose()No description is available for this member.