UnityEngine.RectTransformUtility.RectangleContainsScreenPoint C# (CSharp) Method

RectangleContainsScreenPoint() public static method

Does the RectTransform contain the screen point as seen from the given camera?

public static RectangleContainsScreenPoint ( RectTransform rect, Vector2 screenPoint, Camera cam ) : bool
rect RectTransform The RectTransform to test with.
screenPoint Vector2 The screen point to test.
cam Camera The camera from which the test is performed from. (Optional)
return bool
        public static bool RectangleContainsScreenPoint(RectTransform rect, Vector2 screenPoint, Camera cam)
        {
            return INTERNAL_CALL_RectangleContainsScreenPoint(rect, ref screenPoint, cam);
        }

Same methods

RectTransformUtility::RectangleContainsScreenPoint ( RectTransform rect, Vector2 screenPoint ) : bool

Usage Example

コード例 #1
0
 public static bool RectangleContainsScreenPoint(RectTransform rect, Vector2 screenPoint)
 {
     return(RectTransformUtility.RectangleContainsScreenPoint(rect, screenPoint, null));
 }
All Usage Examples Of UnityEngine.RectTransformUtility::RectangleContainsScreenPoint