docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Class TextureCurve

    A wrapper around AnimationCurve to automatically bake it into a texture.

    Inheritance
    object
    TextureCurve
    Implements
    IDisposable
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: UnityEngine.Rendering
    Assembly: Unity.RenderPipelines.Core.Runtime.dll
    Syntax
    [Serializable]
    public class TextureCurve : IDisposable

    Constructors

    Name Description
    TextureCurve(AnimationCurve, float, bool, in Vector2)

    Creates a new TextureCurve from an existing AnimationCurve.

    TextureCurve(Keyframe[], float, bool, in Vector2)

    Creates a new TextureCurve from an arbitrary number of keyframes.

    Properties

    Name Description
    this[int]

    Retrieves the key at index.

    length

    The number of keys in the curve.

    Methods

    Name Description
    AddKey(float, float)

    Adds a new key to the curve.

    Dispose()

    Cleans up the internal texture resource.

    Evaluate(float)

    Evaluate a time value on the curve.

    ~TextureCurve()

    Finalizer.

    GetTexture()

    Gets the texture representation of this curve.

    MoveKey(int, in Keyframe)

    Removes the keyframe at index and inserts key.

    Release()

    Releases the internal texture resource.

    RemoveKey(int)

    Removes a key.

    SetDirty()

    Marks the curve as dirty to trigger a redraw of the texture the next time GetTexture() is called.

    SmoothTangents(int, float)

    Smoothes the in and out tangents of the keyframe at index. A weight of 0 evens out tangents.

    Extension Methods

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