docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Class TweenableVariableSynchronousBase<T>

    Synchronous implementation of tweenable variable used for types for which it may not be possible to create tween jobs.

    Inheritance
    object
    BindableVariableBase<T>
    BindableVariable<T>
    TweenableVariableBase<T>
    TweenableVariableSynchronousBase<T>
    QuaternionTweenableVariable
    Implements
    IReadOnlyBindableVariable<T>
    Inherited Members
    TweenableVariableBase<T>.k_NearlyOne
    TweenableVariableBase<T>.animationCurve
    TweenableVariableBase<T>.target
    TweenableVariableBase<T>.initialValue
    TweenableVariableBase<T>.HandleTween(float)
    TweenableVariableBase<T>.StartAutoTween(float)
    TweenableVariableBase<T>.PlaySequence(T, T, float, Action)
    TweenableVariableBase<T>.OnAnimationCurveChanged(AnimationCurve)
    TweenableVariableBase<T>.OnTargetChanged(T)
    TweenableVariableBase<T>.PreprocessTween()
    BindableVariable<T>.ValueEquals(T)
    BindableVariableBase<T>.Value
    BindableVariableBase<T>.BindingCount
    BindableVariableBase<T>.SetValueWithoutNotify(T)
    BindableVariableBase<T>.Subscribe(Action<T>)
    BindableVariableBase<T>.SubscribeAndUpdate(Action<T>)
    BindableVariableBase<T>.Unsubscribe(Action<T>)
    BindableVariableBase<T>.BroadcastValue()
    BindableVariableBase<T>.Task(Func<T, bool>, CancellationToken)
    BindableVariableBase<T>.Task(T, CancellationToken)
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: UnityEngine.XR.Interaction.Toolkit.Utilities.Tweenables
    Assembly: Unity.XR.Interaction.Toolkit.dll
    Syntax
    public abstract class TweenableVariableSynchronousBase<T> : TweenableVariableBase<T>, IReadOnlyBindableVariable<T> where T : IEquatable<T>
    Type Parameters
    Name Description
    T

    BindableVariable type.

    Methods

    ExecuteTween(T, T, float, bool)

    Tween from current value to target using tween target.

    Declaration
    protected override void ExecuteTween(T startValue, T targetValue, float tweenAmount, bool useCurve = false)
    Parameters
    Type Name Description
    T startValue

    Tween starting value.

    T targetValue

    Tween target value.

    float tweenAmount

    Value between 0-1 used in tween evaluation.

    bool useCurve

    Whether the animation curve should be used in the tween evaluation.

    Overrides
    TweenableVariableBase<T>.ExecuteTween(T, T, float, bool)
    See Also
    HandleTween(float)

    IsNearlyEqual(T, T)

    Evaluates if the value is nearly equal to target.

    Declaration
    protected abstract bool IsNearlyEqual(T startValue, T targetValue)
    Parameters
    Type Name Description
    T startValue

    First value in equality comparison.

    T targetValue

    Second value in equality comparison.

    Returns
    Type Description
    bool

    Returns true if the values are nearly equal.

    See Also
    TweenableVariableAsyncBase<T>

    Lerp(T, T, float)

    Function used to interpolate between a tween's start value and target value.

    Declaration
    protected abstract T Lerp(T from, T to, float t)
    Parameters
    Type Name Description
    T from

    Tween start value.

    T to

    Tween target value.

    float t

    Value between 0-1 used to evaluate the output between the from and to values.

    Returns
    Type Description
    T

    Returns the interpolation from from to to.

    See Also
    TweenableVariableAsyncBase<T>

    Implements

    Unity.XR.CoreUtils.Bindings.Variables.IReadOnlyBindableVariable<T>

    See Also

    TweenableVariableAsyncBase<T>
    In This Article
    Back to top
    Copyright © 2024 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)