docs.unity3d.com
    Show / Hide Table of Contents

    Method sincos

    sincos(Single, out Single, out Single)

    Returns the sine and cosine of the input float value x through the out parameters s and c.

    Declaration
    public static void sincos(float x, out float s, out float c)
    Parameters
    Type Name Description
    Single x

    Input angle in radians.

    Single s

    Output sine of the input.

    Single c

    Output cosine of the input.

    Remarks

    When Burst compiled, his method is faster than calling sin() and cos() separately.

    sincos(float2, out float2, out float2)

    Returns the componentwise sine and cosine of the input float2 vector x through the out parameters s and c.

    Declaration
    public static void sincos(float2 x, out float2 s, out float2 c)
    Parameters
    Type Name Description
    float2 x

    Input vector containing angles in radians.

    float2 s

    Output vector containing the componentwise sine of the input.

    float2 c

    Output vector containing the componentwise cosine of the input.

    Remarks

    When Burst compiled, his method is faster than calling sin() and cos() separately.

    sincos(float3, out float3, out float3)

    Returns the componentwise sine and cosine of the input float3 vector x through the out parameters s and c.

    Declaration
    public static void sincos(float3 x, out float3 s, out float3 c)
    Parameters
    Type Name Description
    float3 x

    Input vector containing angles in radians.

    float3 s

    Output vector containing the componentwise sine of the input.

    float3 c

    Output vector containing the componentwise cosine of the input.

    Remarks

    When Burst compiled, his method is faster than calling sin() and cos() separately.

    sincos(float4, out float4, out float4)

    Returns the componentwise sine and cosine of the input float4 vector x through the out parameters s and c.

    Declaration
    public static void sincos(float4 x, out float4 s, out float4 c)
    Parameters
    Type Name Description
    float4 x

    Input vector containing angles in radians.

    float4 s

    Output vector containing the componentwise sine of the input.

    float4 c

    Output vector containing the componentwise cosine of the input.

    Remarks

    When Burst compiled, his method is faster than calling sin() and cos() separately.

    sincos(Double, out Double, out Double)

    Returns the sine and cosine of the input double value x through the out parameters s and c.

    Declaration
    public static void sincos(double x, out double s, out double c)
    Parameters
    Type Name Description
    Double x

    Input angle in radians.

    Double s

    Output sine of the input.

    Double c

    Output cosine of the input.

    Remarks

    When Burst compiled, his method is faster than calling sin() and cos() separately.

    sincos(double2, out double2, out double2)

    Returns the componentwise sine and cosine of the input double2 vector x through the out parameters s and c.

    Declaration
    public static void sincos(double2 x, out double2 s, out double2 c)
    Parameters
    Type Name Description
    double2 x

    Input vector containing angles in radians.

    double2 s

    Output vector containing the componentwise sine of the input.

    double2 c

    Output vector containing the componentwise cosine of the input.

    Remarks

    When Burst compiled, his method is faster than calling sin() and cos() separately.

    sincos(double3, out double3, out double3)

    Returns the componentwise sine and cosine of the input double3 vector x through the out parameters s and c.

    Declaration
    public static void sincos(double3 x, out double3 s, out double3 c)
    Parameters
    Type Name Description
    double3 x

    Input vector containing angles in radians.

    double3 s

    Output vector containing the componentwise sine of the input.

    double3 c

    Output vector containing the componentwise cosine of the input.

    Remarks

    When Burst compiled, his method is faster than calling sin() and cos() separately.

    sincos(double4, out double4, out double4)

    Returns the componentwise sine and cosine of the input double4 vector x through the out parameters s and c.

    Declaration
    public static void sincos(double4 x, out double4 s, out double4 c)
    Parameters
    Type Name Description
    double4 x

    Input vector containing angles in radians.

    double4 s

    Output vector containing the componentwise sine of the input.

    double4 c

    Output vector containing the componentwise cosine of the input.

    Remarks

    When Burst compiled, his method is faster than calling sin() and cos() separately.

    In This Article
    • sincos(Single, out Single, out Single)
    • sincos(float2, out float2, out float2)
    • sincos(float3, out float3, out float3)
    • sincos(float4, out float4, out float4)
    • sincos(Double, out Double, out Double)
    • sincos(double2, out double2, out double2)
    • sincos(double3, out double3, out double3)
    • sincos(double4, out double4, out double4)
    Back to top
    Terms of use
    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