mirror of
https://github.com/peng-zhihui/ElectronBot.git
synced 2026-10-21 22:56:26 +08:00
26 lines
667 B
C#
26 lines
667 B
C#
using UnityEngine;
|
|
using UnityEngine.UI;
|
|
|
|
namespace UnityEngine.UI.ProceduralImage
|
|
{
|
|
[DisallowMultipleComponent]
|
|
public abstract class ProceduralImageModifier : MonoBehaviour {
|
|
/// <summary>
|
|
/// Calculates the border-radius for Procedural Image.
|
|
/// </summary>
|
|
/// <returns>The radius as Vector4. (started top-left, clockwise)</returns>
|
|
/// <param name="imageRect">Rect of ProceduralImages RectTransform</param>
|
|
|
|
protected Graphic graphic;
|
|
|
|
protected Graphic _Graphic{
|
|
get{
|
|
if(graphic == null){
|
|
graphic = this.GetComponent<Graphic>();
|
|
}
|
|
return graphic;
|
|
}
|
|
}
|
|
public abstract Vector4 CalculateRadius (Rect imageRect);
|
|
}
|
|
} |