docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Method ProjectOntoPlane

    ProjectOntoPlane(Vector3, Vector3)

    Returns a non-normalized projection of the supplied vector onto a plane as described by its normal

    Declaration
    public static Vector3 ProjectOntoPlane(this Vector3 vector, Vector3 planeNormal)
    Parameters
    Type Name Description
    Vector3 vector

    Vector to project.

    Vector3 planeNormal

    The normal that defines the plane. Must have a length of 1.

    Returns
    Type Description
    Vector3

    The component of the vector that lies in the plane

    In This Article
    Back to top
    Copyright © 2023 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)