docs.unity.cn
    Show / Hide Table of Contents

    Method smoothstep

    smoothstep(Single, Single, Single)

    Returns a smooth Hermite interpolation between 0.0f and 1.0f when x is in the interval (inclusive) [xMin, xMax].

    Declaration
    public static float smoothstep(float xMin, float xMax, float x)
    Parameters
    Type Name Description
    Single xMin

    The minimum range of the x parameter.

    Single xMax

    The maximum range of the x parameter.

    Single x

    The value to be interpolated.

    Returns
    Type Description
    Single

    Returns a value camped to the range [0, 1].

    smoothstep(float2, float2, float2)

    Returns a componentwise smooth Hermite interpolation between 0.0f and 1.0f when x is in the interval (inclusive) [xMin, xMax].

    Declaration
    public static float2 smoothstep(float2 xMin, float2 xMax, float2 x)
    Parameters
    Type Name Description
    float2 xMin

    The minimum range of the x parameter.

    float2 xMax

    The maximum range of the x parameter.

    float2 x

    The value to be interpolated.

    Returns
    Type Description
    float2

    Returns component values camped to the range [0, 1].

    smoothstep(float3, float3, float3)

    Returns a componentwise smooth Hermite interpolation between 0.0f and 1.0f when x is in the interval (inclusive) [xMin, xMax].

    Declaration
    public static float3 smoothstep(float3 xMin, float3 xMax, float3 x)
    Parameters
    Type Name Description
    float3 xMin

    The minimum range of the x parameter.

    float3 xMax

    The maximum range of the x parameter.

    float3 x

    The value to be interpolated.

    Returns
    Type Description
    float3

    Returns component values camped to the range [0, 1].

    smoothstep(float4, float4, float4)

    Returns a componentwise smooth Hermite interpolation between 0.0f and 1.0f when x is in the interval (inclusive) [xMin, xMax].

    Declaration
    public static float4 smoothstep(float4 xMin, float4 xMax, float4 x)
    Parameters
    Type Name Description
    float4 xMin

    The minimum range of the x parameter.

    float4 xMax

    The maximum range of the x parameter.

    float4 x

    The value to be interpolated.

    Returns
    Type Description
    float4

    Returns component values camped to the range [0, 1].

    smoothstep(Double, Double, Double)

    Returns a smooth Hermite interpolation between 0.0 and 1.0 when x is in the interval (inclusive) [xMin, xMax].

    Declaration
    public static double smoothstep(double xMin, double xMax, double x)
    Parameters
    Type Name Description
    Double xMin

    The minimum range of the x parameter.

    Double xMax

    The maximum range of the x parameter.

    Double x

    The value to be interpolated.

    Returns
    Type Description
    Double

    Returns a value camped to the range [0, 1].

    smoothstep(double2, double2, double2)

    Returns a componentwise smooth Hermite interpolation between 0.0 and 1.0 when x is in the interval (inclusive) [xMin, xMax].

    Declaration
    public static double2 smoothstep(double2 xMin, double2 xMax, double2 x)
    Parameters
    Type Name Description
    double2 xMin

    The minimum range of the x parameter.

    double2 xMax

    The maximum range of the x parameter.

    double2 x

    The value to be interpolated.

    Returns
    Type Description
    double2

    Returns component values camped to the range [0, 1].

    smoothstep(double3, double3, double3)

    Returns a componentwise smooth Hermite interpolation between 0.0 and 1.0 when x is in the interval (inclusive) [xMin, xMax].

    Declaration
    public static double3 smoothstep(double3 xMin, double3 xMax, double3 x)
    Parameters
    Type Name Description
    double3 xMin

    The minimum range of the x parameter.

    double3 xMax

    The maximum range of the x parameter.

    double3 x

    The value to be interpolated.

    Returns
    Type Description
    double3

    Returns component values camped to the range [0, 1].

    smoothstep(double4, double4, double4)

    Returns a componentwise smooth Hermite interpolation between 0.0 and 1.0 when x is in the interval (inclusive) [xMin, xMax].

    Declaration
    public static double4 smoothstep(double4 xMin, double4 xMax, double4 x)
    Parameters
    Type Name Description
    double4 xMin

    The minimum range of the x parameter.

    double4 xMax

    The maximum range of the x parameter.

    double4 x

    The value to be interpolated.

    Returns
    Type Description
    double4

    Returns component values camped to the range [0, 1].

    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023