C# Class RectExtension, UnityToolbag

Mostra file Open project: ChemiKhazi/UnityToolbag Class Usage Examples

Public Methods

Method Description
GetRectAsLocal ( this target, RectTransform other, Camera cam = null ) : Rect

Get other RectTransform as a Rect in local space of this RectTransform

GetScreenRect ( this target, Camera cam = null ) : Rect
ScreenAlign ( this input, SpriteAlignment align ) : Rect

Method Details

GetRectAsLocal() public static method

Get other RectTransform as a Rect in local space of this RectTransform
public static GetRectAsLocal ( this target, RectTransform other, Camera cam = null ) : Rect
target this
other UnityEngine.RectTransform
cam Camera
return Rect

GetScreenRect() public static method

public static GetScreenRect ( this target, Camera cam = null ) : Rect
target this
cam Camera
return Rect

ScreenAlign() public static method

public static ScreenAlign ( this input, SpriteAlignment align ) : Rect
input this
align SpriteAlignment
return Rect