docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Struct CapsuleGeometry

    A capsule geometry.

    Implements
    IEquatable<CapsuleGeometry>
    Inherited Members
    ValueType.Equals(object)
    ValueType.ToString()
    object.Equals(object, object)
    object.GetType()
    object.ReferenceEquals(object, object)
    Namespace: Unity.Physics
    Assembly: Unity.Physics.dll
    Syntax
    public struct CapsuleGeometry : IEquatable<CapsuleGeometry>

    Properties

    Radius

    The radius of the capsule around the line segment.

    Declaration
    public float Radius { get; set; }
    Property Value
    Type Description
    float

    The radius.

    Vertex0

    The start position of the capsule's inner line segment.

    Declaration
    public float3 Vertex0 { get; set; }
    Property Value
    Type Description
    float3

    The start position of the capsule's inner line segment.

    Vertex1

    The end position of the capsule's inner line segment.

    Declaration
    public float3 Vertex1 { get; set; }
    Property Value
    Type Description
    float3

    The end position of the capsule's inner line segment.

    Methods

    Equals(CapsuleGeometry)

    Tests if this CapsuleGeometry is considered equal to another.

    Declaration
    public bool Equals(CapsuleGeometry other)
    Parameters
    Type Name Description
    CapsuleGeometry other

    The capsule geometry to compare to this object.

    Returns
    Type Description
    bool

    True if the objects are considered equal, false if they are not.

    GetCenter()

    The center of the capsule.

    Declaration
    public float3 GetCenter()
    Returns
    Type Description
    float3

    The center.

    GetHashCode()

    Calculates a hash code for this object.

    Declaration
    public override int GetHashCode()
    Returns
    Type Description
    int

    A hash code for this object.

    Overrides
    ValueType.GetHashCode()

    GetHeight()

    The height of the capsule.

    Declaration
    public float GetHeight()
    Returns
    Type Description
    float

    The height.

    Implements

    IEquatable<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)