1.0.0-preview.5
# [1.0.0-preview.5](https://github.com/mob-sakai/SoftMaskForUGUI/compare/v1.0.0-preview.4...v1.0.0-preview.5) (2020-06-09) ### Bug Fixes * screen space overlay bug with game window resize ([pull/122/head91b7788
](91b77885bc
)), closes [#93](https://github.com/mob-sakai/SoftMaskForUGUI/issues/93)
parent
9aa9f568b8
commit
03a7b84fa2
|
@ -1,3 +1,10 @@
|
||||||
|
# [1.0.0-preview.5](https://github.com/mob-sakai/SoftMaskForUGUI/compare/v1.0.0-preview.4...v1.0.0-preview.5) (2020-06-09)
|
||||||
|
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* screen space overlay bug with game window resize ([91b7788](https://github.com/mob-sakai/SoftMaskForUGUI/commit/91b77885bc5f60cb59e8081009982a4635f9245c)), closes [#93](https://github.com/mob-sakai/SoftMaskForUGUI/issues/93)
|
||||||
|
|
||||||
# [1.0.0-preview.4](https://github.com/mob-sakai/SoftMaskForUGUI/compare/v1.0.0-preview.3...v1.0.0-preview.4) (2020-06-07)
|
# [1.0.0-preview.4](https://github.com/mob-sakai/SoftMaskForUGUI/compare/v1.0.0-preview.3...v1.0.0-preview.4) (2020-06-07)
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -14,6 +14,7 @@ namespace Coffee.UISoftMask
|
||||||
[CanEditMultipleObjects]
|
[CanEditMultipleObjects]
|
||||||
public class SoftMaskEditor : Editor
|
public class SoftMaskEditor : Editor
|
||||||
{
|
{
|
||||||
|
private const int k_PreviewSize = 128;
|
||||||
private const string k_PrefsPreview = "SoftMaskEditor_Preview";
|
private const string k_PrefsPreview = "SoftMaskEditor_Preview";
|
||||||
private static readonly List<Graphic> s_Graphics = new List<Graphic>();
|
private static readonly List<Graphic> s_Graphics = new List<Graphic>();
|
||||||
private static bool s_Preview;
|
private static bool s_Preview;
|
||||||
|
@ -29,9 +30,10 @@ namespace Coffee.UISoftMask
|
||||||
|
|
||||||
var current = target as SoftMask;
|
var current = target as SoftMask;
|
||||||
current.GetComponentsInChildren<Graphic>(true, s_Graphics);
|
current.GetComponentsInChildren<Graphic>(true, s_Graphics);
|
||||||
var fixTargets = s_Graphics.Where(x =>
|
var fixTargets = s_Graphics
|
||||||
x.gameObject != current.gameObject && !x.GetComponent<SoftMaskable>() &&
|
.Where(x => x.gameObject != current.gameObject)
|
||||||
(!x.GetComponent<Mask>() || x.GetComponent<Mask>().showMaskGraphic)).ToList();
|
.Where(x => !x.GetComponent<SoftMaskable>() && (!x.GetComponent<Mask>() || x.GetComponent<Mask>().showMaskGraphic))
|
||||||
|
.ToList();
|
||||||
if (0 < fixTargets.Count)
|
if (0 < fixTargets.Count)
|
||||||
{
|
{
|
||||||
GUILayout.BeginHorizontal();
|
GUILayout.BeginHorizontal();
|
||||||
|
@ -58,7 +60,7 @@ namespace Coffee.UISoftMask
|
||||||
|
|
||||||
// Preview buffer.
|
// Preview buffer.
|
||||||
GUILayout.BeginVertical(EditorStyles.helpBox);
|
GUILayout.BeginVertical(EditorStyles.helpBox);
|
||||||
if (s_Preview != (s_Preview = EditorGUILayout.ToggleLeft("Preview Buffer", s_Preview)))
|
if (s_Preview != (s_Preview = EditorGUILayout.ToggleLeft("Preview Soft Mask Buffer", s_Preview)))
|
||||||
{
|
{
|
||||||
EditorPrefs.SetBool(k_PrefsPreview, s_Preview);
|
EditorPrefs.SetBool(k_PrefsPreview, s_Preview);
|
||||||
}
|
}
|
||||||
|
@ -66,10 +68,11 @@ namespace Coffee.UISoftMask
|
||||||
if (s_Preview)
|
if (s_Preview)
|
||||||
{
|
{
|
||||||
var tex = current.softMaskBuffer;
|
var tex = current.softMaskBuffer;
|
||||||
var width = tex.width * 128 / tex.height;
|
var width = tex.width * k_PreviewSize / tex.height;
|
||||||
EditorGUI.DrawPreviewTexture(GUILayoutUtility.GetRect(width, 128), tex, null, ScaleMode.ScaleToFit);
|
EditorGUI.DrawPreviewTexture(GUILayoutUtility.GetRect(width, k_PreviewSize), tex, null, ScaleMode.ScaleToFit);
|
||||||
Repaint();
|
Repaint();
|
||||||
}
|
}
|
||||||
|
|
||||||
GUILayout.EndVertical();
|
GUILayout.EndVertical();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -55,6 +55,8 @@ namespace Coffee.UISoftMask
|
||||||
private static int s_GameVPId;
|
private static int s_GameVPId;
|
||||||
private static int s_GameTVPId;
|
private static int s_GameTVPId;
|
||||||
private static int s_Alpha;
|
private static int s_Alpha;
|
||||||
|
private static int s_PreviousWidth;
|
||||||
|
private static int s_PreviousHeight;
|
||||||
private MaterialPropertyBlock _mpb;
|
private MaterialPropertyBlock _mpb;
|
||||||
private CommandBuffer _cb;
|
private CommandBuffer _cb;
|
||||||
private Material _material;
|
private Material _material;
|
||||||
|
@ -76,7 +78,7 @@ namespace Coffee.UISoftMask
|
||||||
[SerializeField, Range(0f, 1f), Tooltip("The transparency of the whole masked graphic.")]
|
[SerializeField, Range(0f, 1f), Tooltip("The transparency of the whole masked graphic.")]
|
||||||
private float m_Alpha = 1;
|
private float m_Alpha = 1;
|
||||||
|
|
||||||
[SerializeField, Tooltip("Should the soft mask ignore parent soft masks?")]
|
[Header("Advanced Options")] [SerializeField, Tooltip("Should the soft mask ignore parent soft masks?")]
|
||||||
private bool m_IgnoreParent = false;
|
private bool m_IgnoreParent = false;
|
||||||
|
|
||||||
[SerializeField, Tooltip("Is the soft mask a part of parent soft mask?")]
|
[SerializeField, Tooltip("Is the soft mask a part of parent soft mask?")]
|
||||||
|
@ -187,8 +189,7 @@ namespace Coffee.UISoftMask
|
||||||
|
|
||||||
if (!_softMaskBuffer)
|
if (!_softMaskBuffer)
|
||||||
{
|
{
|
||||||
_softMaskBuffer = RenderTexture.GetTemporary(w, h, 0, RenderTextureFormat.ARGB32,
|
_softMaskBuffer = RenderTexture.GetTemporary(w, h, 0, RenderTextureFormat.ARGB32, RenderTextureReadWrite.Default);
|
||||||
RenderTextureReadWrite.Default);
|
|
||||||
hasChanged = true;
|
hasChanged = true;
|
||||||
_hasStencilStateChanged = true;
|
_hasStencilStateChanged = true;
|
||||||
}
|
}
|
||||||
|
@ -242,7 +243,6 @@ namespace Coffee.UISoftMask
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Material material
|
Material material
|
||||||
{
|
{
|
||||||
get
|
get
|
||||||
|
@ -251,9 +251,8 @@ namespace Coffee.UISoftMask
|
||||||
? _material
|
? _material
|
||||||
: _material =
|
: _material =
|
||||||
new Material(s_SoftMaskShader
|
new Material(s_SoftMaskShader
|
||||||
? s_SoftMaskShader
|
? s_SoftMaskShader
|
||||||
: s_SoftMaskShader = Resources.Load<Shader>("SoftMask"))
|
: s_SoftMaskShader = Resources.Load<Shader>("SoftMask")) {hideFlags = HideFlags.HideAndDontSave};
|
||||||
{hideFlags = HideFlags.HideAndDontSave};
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -547,6 +546,16 @@ namespace Coffee.UISoftMask
|
||||||
Profiler.EndSample();
|
Profiler.EndSample();
|
||||||
|
|
||||||
Profiler.EndSample();
|
Profiler.EndSample();
|
||||||
|
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
var w = s_PreviousWidth;
|
||||||
|
var h = s_PreviousHeight;
|
||||||
|
GetDesamplingSize(DesamplingRate.None, out s_PreviousWidth, out s_PreviousHeight);
|
||||||
|
if (w != s_PreviousWidth || h != s_PreviousHeight)
|
||||||
|
{
|
||||||
|
Canvas.ForceUpdateCanvases();
|
||||||
|
}
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
@ -558,8 +567,7 @@ namespace Coffee.UISoftMask
|
||||||
Profiler.BeginSample("UpdateMaskTexture");
|
Profiler.BeginSample("UpdateMaskTexture");
|
||||||
|
|
||||||
|
|
||||||
_stencilDepth =
|
_stencilDepth = MaskUtilities.GetStencilDepth(transform, MaskUtilities.FindRootSortOverrideCanvas(transform));
|
||||||
MaskUtilities.GetStencilDepth(transform, MaskUtilities.FindRootSortOverrideCanvas(transform));
|
|
||||||
|
|
||||||
// Collect children soft masks.
|
// Collect children soft masks.
|
||||||
Profiler.BeginSample("Collect children soft masks");
|
Profiler.BeginSample("Collect children soft masks");
|
||||||
|
@ -570,7 +578,7 @@ namespace Coffee.UISoftMask
|
||||||
var count = s_TmpSoftMasks[depth].Count;
|
var count = s_TmpSoftMasks[depth].Count;
|
||||||
for (var i = 0; i < count; i++)
|
for (var i = 0; i < count; i++)
|
||||||
{
|
{
|
||||||
List<SoftMask> children = s_TmpSoftMasks[depth][i]._children;
|
var children = s_TmpSoftMasks[depth][i]._children;
|
||||||
var childCount = children.Count;
|
var childCount = children.Count;
|
||||||
for (var j = 0; j < childCount; j++)
|
for (var j = 0; j < childCount; j++)
|
||||||
{
|
{
|
||||||
|
@ -598,11 +606,11 @@ namespace Coffee.UISoftMask
|
||||||
var cam = c.worldCamera ?? Camera.main;
|
var cam = c.worldCamera ?? Camera.main;
|
||||||
if (c && c.renderMode != RenderMode.ScreenSpaceOverlay && cam)
|
if (c && c.renderMode != RenderMode.ScreenSpaceOverlay && cam)
|
||||||
{
|
{
|
||||||
_cb.SetViewProjectionMatrices(cam.worldToCameraMatrix,
|
var p = GL.GetGPUProjectionMatrix(cam.projectionMatrix, false);
|
||||||
GL.GetGPUProjectionMatrix(cam.projectionMatrix, false));
|
_cb.SetViewProjectionMatrices(cam.worldToCameraMatrix, p);
|
||||||
|
|
||||||
#if UNITY_EDITOR
|
#if UNITY_EDITOR
|
||||||
var pv = GL.GetGPUProjectionMatrix(cam.projectionMatrix, false) * cam.worldToCameraMatrix;
|
var pv = p * cam.worldToCameraMatrix;
|
||||||
_cb.SetGlobalMatrix(s_GameVPId, pv);
|
_cb.SetGlobalMatrix(s_GameVPId, pv);
|
||||||
_cb.SetGlobalMatrix(s_GameTVPId, pv);
|
_cb.SetGlobalMatrix(s_GameTVPId, pv);
|
||||||
#endif
|
#endif
|
||||||
|
@ -611,19 +619,16 @@ namespace Coffee.UISoftMask
|
||||||
{
|
{
|
||||||
var pos = c.transform.position;
|
var pos = c.transform.position;
|
||||||
var vm = Matrix4x4.TRS(new Vector3(-pos.x, -pos.y, -1000), Quaternion.identity, new Vector3(1, 1, -1f));
|
var vm = Matrix4x4.TRS(new Vector3(-pos.x, -pos.y, -1000), Quaternion.identity, new Vector3(1, 1, -1f));
|
||||||
var pm = Matrix4x4.TRS(new Vector3(0, 0, -1), Quaternion.identity,
|
var pm = Matrix4x4.TRS(new Vector3(0, 0, -1), Quaternion.identity, new Vector3(1 / pos.x, 1 / pos.y, -2 / 10000f));
|
||||||
new Vector3(1 / pos.x, 1 / pos.y, -2 / 10000f));
|
|
||||||
_cb.SetViewProjectionMatrices(vm, pm);
|
_cb.SetViewProjectionMatrices(vm, pm);
|
||||||
|
|
||||||
#if UNITY_EDITOR
|
#if UNITY_EDITOR
|
||||||
var scale = c.transform.localScale.x;
|
var scale = c.transform.localScale.x;
|
||||||
var size = (c.transform as RectTransform).sizeDelta;
|
var size = (c.transform as RectTransform).sizeDelta;
|
||||||
_cb.SetGlobalMatrix(s_GameVPId,
|
var gameVp = Matrix4x4.TRS(new Vector3(0, 0, 0.5f), Quaternion.identity, new Vector3(2 / size.x, 2 / size.y, 0.0005f * scale));
|
||||||
Matrix4x4.TRS(new Vector3(0, 0, 0.5f), Quaternion.identity,
|
var gameTvp = Matrix4x4.TRS(new Vector3(0, 0, 0), Quaternion.identity, new Vector3(1 / pos.x, 1 / pos.y, -2 / 2000f)) * Matrix4x4.Translate(-pos);
|
||||||
new Vector3(2 / size.x, 2 / size.y, 0.0005f * scale)));
|
_cb.SetGlobalMatrix(s_GameVPId, gameVp);
|
||||||
_cb.SetGlobalMatrix(s_GameTVPId,
|
_cb.SetGlobalMatrix(s_GameTVPId, gameTvp);
|
||||||
Matrix4x4.TRS(new Vector3(0, 0, 0), Quaternion.identity,
|
|
||||||
new Vector3(1 / pos.x, 1 / pos.y, -2 / 2000f)) * Matrix4x4.Translate(-pos));
|
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -640,8 +645,7 @@ namespace Coffee.UISoftMask
|
||||||
|
|
||||||
if (i != 0)
|
if (i != 0)
|
||||||
{
|
{
|
||||||
sm._stencilDepth = MaskUtilities.GetStencilDepth(sm.transform,
|
sm._stencilDepth = MaskUtilities.GetStencilDepth(sm.transform, MaskUtilities.FindRootSortOverrideCanvas(sm.transform));
|
||||||
MaskUtilities.FindRootSortOverrideCanvas(sm.transform));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Set material property.
|
// Set material property.
|
||||||
|
@ -700,6 +704,7 @@ namespace Coffee.UISoftMask
|
||||||
private static void ReleaseRt(ref RenderTexture tmpRT)
|
private static void ReleaseRt(ref RenderTexture tmpRT)
|
||||||
{
|
{
|
||||||
if (!tmpRT) return;
|
if (!tmpRT) return;
|
||||||
|
|
||||||
tmpRT.Release();
|
tmpRT.Release();
|
||||||
RenderTexture.ReleaseTemporary(tmpRT);
|
RenderTexture.ReleaseTemporary(tmpRT);
|
||||||
tmpRT = null;
|
tmpRT = null;
|
||||||
|
@ -712,13 +717,13 @@ namespace Coffee.UISoftMask
|
||||||
private static void ReleaseObject(Object obj)
|
private static void ReleaseObject(Object obj)
|
||||||
{
|
{
|
||||||
if (!obj) return;
|
if (!obj) return;
|
||||||
|
|
||||||
#if UNITY_EDITOR
|
#if UNITY_EDITOR
|
||||||
if (!Application.isPlaying)
|
if (!Application.isPlaying)
|
||||||
DestroyImmediate(obj);
|
DestroyImmediate(obj);
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
Destroy(obj);
|
Destroy(obj);
|
||||||
obj = null;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -133,8 +133,7 @@ namespace Coffee.UISoftMask
|
||||||
mat.EnableKeyword("SOFTMASK_EDITOR");
|
mat.EnableKeyword("SOFTMASK_EDITOR");
|
||||||
#endif
|
#endif
|
||||||
mat.SetTexture(s_SoftMaskTexId, softMask.softMaskBuffer);
|
mat.SetTexture(s_SoftMaskTexId, softMask.softMaskBuffer);
|
||||||
mat.SetInt(s_StencilCompId,
|
mat.SetInt(s_StencilCompId, m_UseStencil ? (int) CompareFunction.Equal : (int) CompareFunction.Always);
|
||||||
m_UseStencil ? (int) CompareFunction.Equal : (int) CompareFunction.Always);
|
|
||||||
|
|
||||||
var root = MaskUtilities.FindRootSortOverrideCanvas(transform);
|
var root = MaskUtilities.FindRootSortOverrideCanvas(transform);
|
||||||
var stencil = MaskUtilities.GetStencilDepth(transform, root);
|
var stencil = MaskUtilities.GetStencilDepth(transform, root);
|
||||||
|
@ -179,15 +178,19 @@ namespace Coffee.UISoftMask
|
||||||
for (var i = 0; i < 4; i++)
|
for (var i = 0; i < 4; i++)
|
||||||
{
|
{
|
||||||
if (!sm) break;
|
if (!sm) break;
|
||||||
|
|
||||||
s_Interactions[i] = sm ? ((m_MaskInteraction >> i * 2) & 0x3) : 0;
|
s_Interactions[i] = sm ? ((m_MaskInteraction >> i * 2) & 0x3) : 0;
|
||||||
var interaction = s_Interactions[i] == 1;
|
var interaction = s_Interactions[i] == 1;
|
||||||
var inRect = RectTransformUtility.RectangleContainsScreenPoint(sm.transform as RectTransform, sp, eventCamera);
|
var rt = sm.transform as RectTransform;
|
||||||
|
var inRect = RectTransformUtility.RectangleContainsScreenPoint(rt, sp, eventCamera);
|
||||||
if (!sm.ignoreSelfGraphic && interaction != inRect) return false;
|
if (!sm.ignoreSelfGraphic && interaction != inRect) return false;
|
||||||
|
|
||||||
foreach (var child in sm._children)
|
foreach (var child in sm._children)
|
||||||
{
|
{
|
||||||
if (!child) break;
|
if (!child) continue;
|
||||||
var inRectChild = RectTransformUtility.RectangleContainsScreenPoint(child.transform as RectTransform, sp, eventCamera);
|
|
||||||
|
var childRt = child.transform as RectTransform;
|
||||||
|
var inRectChild = RectTransformUtility.RectangleContainsScreenPoint(childRt, sp, eventCamera);
|
||||||
if (!child.ignoreSelfGraphic && interaction != inRectChild) return false;
|
if (!child.ignoreSelfGraphic && interaction != inRectChild) return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -201,7 +204,7 @@ namespace Coffee.UISoftMask
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Set the interaction for each mask.
|
/// Set the interaction for each mask.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public void SetMaskInteraction(SpriteMaskInteraction intr)
|
public void SetMaskInteraction(MaskIntr intr)
|
||||||
{
|
{
|
||||||
SetMaskInteraction(intr, intr, intr, intr);
|
SetMaskInteraction(intr, intr, intr, intr);
|
||||||
}
|
}
|
||||||
|
@ -209,8 +212,7 @@ namespace Coffee.UISoftMask
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Set the interaction for each mask.
|
/// Set the interaction for each mask.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public void SetMaskInteraction(SpriteMaskInteraction layer0, SpriteMaskInteraction layer1,
|
public void SetMaskInteraction(MaskIntr layer0, MaskIntr layer1, MaskIntr layer2, MaskIntr layer3)
|
||||||
SpriteMaskInteraction layer2, SpriteMaskInteraction layer3)
|
|
||||||
{
|
{
|
||||||
m_MaskInteraction = (int) layer0 + ((int) layer1 << 2) + ((int) layer2 << 4) + ((int) layer3 << 6);
|
m_MaskInteraction = (int) layer0 + ((int) layer1 << 2) + ((int) layer2 << 4) + ((int) layer3 << 6);
|
||||||
graphic.SetMaterialDirtyEx();
|
graphic.SetMaterialDirtyEx();
|
||||||
|
@ -278,12 +280,14 @@ namespace Coffee.UISoftMask
|
||||||
var current = this;
|
var current = this;
|
||||||
UnityEditor.EditorApplication.delayCall += () =>
|
UnityEditor.EditorApplication.delayCall += () =>
|
||||||
{
|
{
|
||||||
if (current && graphic && graphic.material && graphic.material.shader &&
|
if (!current) return;
|
||||||
graphic.material.shader.name == "Hidden/UI/Default (SoftMaskable)")
|
if (!graphic) return;
|
||||||
{
|
if (!graphic.material) return;
|
||||||
graphic.material = null;
|
if (!graphic.material.shader) return;
|
||||||
graphic.SetMaterialDirtyEx();
|
if (graphic.material.shader.name != "Hidden/UI/Default (SoftMaskable)") return;
|
||||||
}
|
|
||||||
|
graphic.material = null;
|
||||||
|
graphic.SetMaterialDirtyEx();
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -7,6 +7,17 @@ float4x4 _GameVP;
|
||||||
float4x4 _GameTVP;
|
float4x4 _GameTVP;
|
||||||
half4 _MaskInteraction;
|
half4 _MaskInteraction;
|
||||||
|
|
||||||
|
fixed Approximately(float4x4 a, float4x4 b)
|
||||||
|
{
|
||||||
|
float4x4 d = abs(a - b);
|
||||||
|
return step(
|
||||||
|
max(d._m00,max(d._m01,max(d._m02,max(d._m03,
|
||||||
|
max(d._m10,max(d._m11,max(d._m12,max(d._m13,
|
||||||
|
max(d._m20,max(d._m21,max(d._m22,max(d._m23,
|
||||||
|
max(d._m30,max(d._m31,max(d._m32,d._m33))))))))))))))),
|
||||||
|
0.5);
|
||||||
|
}
|
||||||
|
|
||||||
#if SOFTMASK_EDITOR
|
#if SOFTMASK_EDITOR
|
||||||
float SoftMaskInternal(float4 clipPos, float4 wpos)
|
float SoftMaskInternal(float4 clipPos, float4 wpos)
|
||||||
#else
|
#else
|
||||||
|
@ -15,7 +26,7 @@ float SoftMaskInternal(float4 clipPos)
|
||||||
{
|
{
|
||||||
half2 view = clipPos.xy/_ScreenParams.xy;
|
half2 view = clipPos.xy/_ScreenParams.xy;
|
||||||
#if SOFTMASK_EDITOR
|
#if SOFTMASK_EDITOR
|
||||||
fixed isSceneView = any(UNITY_MATRIX_VP - _GameVP);
|
fixed isSceneView = 1 - Approximately(UNITY_MATRIX_VP, _GameVP);
|
||||||
float4 cpos = mul(_GameTVP, mul(UNITY_MATRIX_M, wpos));
|
float4 cpos = mul(_GameTVP, mul(UNITY_MATRIX_M, wpos));
|
||||||
view = lerp(view, cpos.xy / cpos.w * 0.5 + 0.5, isSceneView);
|
view = lerp(view, cpos.xy / cpos.w * 0.5 + 0.5, isSceneView);
|
||||||
#if UNITY_UV_STARTS_AT_TOP
|
#if UNITY_UV_STARTS_AT_TOP
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
"name": "com.coffee.softmask-for-ugui",
|
"name": "com.coffee.softmask-for-ugui",
|
||||||
"displayName": "UI Soft Mask",
|
"displayName": "UI Soft Mask",
|
||||||
"description": "UI Soft Mask is a smooth masking component for Unity UI (uGUI) elements.\nBy using SoftMask instead of the default Mask component, you can beautifully represent the rounded edges of UI elements.",
|
"description": "UI Soft Mask is a smooth masking component for Unity UI (uGUI) elements.\nBy using SoftMask instead of the default Mask component, you can beautifully represent the rounded edges of UI elements.",
|
||||||
"version": "1.0.0-preview.4",
|
"version": "1.0.0-preview.5",
|
||||||
"unity": "2017.1",
|
"unity": "2017.1",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"repository": {
|
"repository": {
|
||||||
|
|
Loading…
Reference in New Issue