docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Method dot

    dot(int, int)

    Returns the dot product of two int values. Equivalent to multiplication.

    Declaration
    public static int dot(int x, int y)
    Parameters
    Type Name Description
    int x

    The first value.

    int y

    The second value.

    Returns
    Type Description
    int

    The dot product of two values.

    dot(int2, int2)

    Returns the dot product of two int2 vectors.

    Declaration
    public static int dot(int2 x, int2 y)
    Parameters
    Type Name Description
    int2 x

    The first vector.

    int2 y

    The second vector.

    Returns
    Type Description
    int

    The dot product of two vectors.

    dot(int3, int3)

    Returns the dot product of two int3 vectors.

    Declaration
    public static int dot(int3 x, int3 y)
    Parameters
    Type Name Description
    int3 x

    The first vector.

    int3 y

    The second vector.

    Returns
    Type Description
    int

    The dot product of two vectors.

    dot(int4, int4)

    Returns the dot product of two int4 vectors.

    Declaration
    public static int dot(int4 x, int4 y)
    Parameters
    Type Name Description
    int4 x

    The first vector.

    int4 y

    The second vector.

    Returns
    Type Description
    int

    The dot product of two vectors.

    dot(uint, uint)

    Returns the dot product of two uint values. Equivalent to multiplication.

    Declaration
    public static uint dot(uint x, uint y)
    Parameters
    Type Name Description
    uint x

    The first value.

    uint y

    The second value.

    Returns
    Type Description
    uint

    The dot product of two values.

    dot(uint2, uint2)

    Returns the dot product of two uint2 vectors.

    Declaration
    public static uint dot(uint2 x, uint2 y)
    Parameters
    Type Name Description
    uint2 x

    The first vector.

    uint2 y

    The second vector.

    Returns
    Type Description
    uint

    The dot product of two vectors.

    dot(uint3, uint3)

    Returns the dot product of two uint3 vectors.

    Declaration
    public static uint dot(uint3 x, uint3 y)
    Parameters
    Type Name Description
    uint3 x

    The first vector.

    uint3 y

    The second vector.

    Returns
    Type Description
    uint

    The dot product of two vectors.

    dot(uint4, uint4)

    Returns the dot product of two uint4 vectors.

    Declaration
    public static uint dot(uint4 x, uint4 y)
    Parameters
    Type Name Description
    uint4 x

    The first vector.

    uint4 y

    The second vector.

    Returns
    Type Description
    uint

    The dot product of two vectors.

    dot(float, float)

    Returns the dot product of two float values. Equivalent to multiplication.

    Declaration
    public static float dot(float x, float y)
    Parameters
    Type Name Description
    float x

    The first value.

    float y

    The second value.

    Returns
    Type Description
    float

    The dot product of two values.

    dot(float2, float2)

    Returns the dot product of two float2 vectors.

    Declaration
    public static float dot(float2 x, float2 y)
    Parameters
    Type Name Description
    float2 x

    The first vector.

    float2 y

    The second vector.

    Returns
    Type Description
    float

    The dot product of two vectors.

    dot(float3, float3)

    Returns the dot product of two float3 vectors.

    Declaration
    public static float dot(float3 x, float3 y)
    Parameters
    Type Name Description
    float3 x

    The first vector.

    float3 y

    The second vector.

    Returns
    Type Description
    float

    The dot product of two vectors.

    dot(float4, float4)

    Returns the dot product of two float4 vectors.

    Declaration
    public static float dot(float4 x, float4 y)
    Parameters
    Type Name Description
    float4 x

    The first vector.

    float4 y

    The second vector.

    Returns
    Type Description
    float

    The dot product of two vectors.

    dot(double, double)

    Returns the dot product of two double values. Equivalent to multiplication.

    Declaration
    public static double dot(double x, double y)
    Parameters
    Type Name Description
    double x

    The first value.

    double y

    The second value.

    Returns
    Type Description
    double

    The dot product of two values.

    dot(double2, double2)

    Returns the dot product of two double2 vectors.

    Declaration
    public static double dot(double2 x, double2 y)
    Parameters
    Type Name Description
    double2 x

    The first vector.

    double2 y

    The second vector.

    Returns
    Type Description
    double

    The dot product of two vectors.

    dot(double3, double3)

    Returns the dot product of two double3 vectors.

    Declaration
    public static double dot(double3 x, double3 y)
    Parameters
    Type Name Description
    double3 x

    The first vector.

    double3 y

    The second vector.

    Returns
    Type Description
    double

    The dot product of two vectors.

    dot(double4, double4)

    Returns the dot product of two double4 vectors.

    Declaration
    public static double dot(double4 x, double4 y)
    Parameters
    Type Name Description
    double4 x

    The first vector.

    double4 y

    The second vector.

    Returns
    Type Description
    double

    The dot product of two vectors.

    dot(quaternion, quaternion)

    Returns the dot product of two quaternions.

    Declaration
    public static float dot(quaternion a, quaternion b)
    Parameters
    Type Name Description
    quaternion a

    The first quaternion.

    quaternion b

    The second quaternion.

    Returns
    Type Description
    float

    The dot product of two quaternions.

    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)