ドキュメント

Unity Engine

Download Unity

Unity Engine

SignedDistanceToPoint(float3)

Get the signed distance from the point to the plane.
読み終わるまでの所要時間 1 分最終更新 3時間前

Definition

public float SignedDistanceToPoint(float3 point)

Parameters

point

Point to find the signed distance with.

Returns

Type

Description

floatSigned distance of the point from the plane.

Remarks

Plane must be normalized prior to calling this function. Distance is positive if point is on side of the plane the normal points to, negative if on the opposite side and zero if the point lies in the plane. Avoid comparing equality with 0.0f when testing if a point lies exactly in the plane and use an approximate comparison instead.