mirror of
https://github.com/mob-sakai/UIEffect.git
synced 2026-11-20 01:42:37 +08:00
Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 6f90044ec8 | |||
| 83128ebb09 | |||
| 9dffdb0ed8 |
@@ -1,3 +1,11 @@
|
||||
## [5.9.6](https://github.com/mob-sakai/UIEffect/compare/5.9.5...5.9.6) (2025-07-17)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* `ColorFilter` does not output intended color when vertex color is not white ([9dffdb0](https://github.com/mob-sakai/UIEffect/commit/9dffdb0ed88750a915fdd5e437b79ab766ce45c2)), closes [#363](https://github.com/mob-sakai/UIEffect/issues/363)
|
||||
* draw calls increase even when using `UIEffectReplica` ([83128eb](https://github.com/mob-sakai/UIEffect/commit/83128ebb09305e4c15a58968a94550179e96ffac)), closes [#364](https://github.com/mob-sakai/UIEffect/issues/364)
|
||||
|
||||
## [5.9.5](https://github.com/mob-sakai/UIEffect/compare/5.9.4...5.9.5) (2025-06-26)
|
||||
|
||||
|
||||
|
||||
@@ -99,7 +99,12 @@ namespace Coffee.UIEffects
|
||||
|
||||
public override bool canModifyShape => m_AllowToModifyMeshShape;
|
||||
|
||||
public override uint effectId => target ? target.effectId : 0;
|
||||
public override uint effectId => target
|
||||
? target.effectId
|
||||
: preset
|
||||
? (uint)preset.GetInstanceID()
|
||||
: (uint)GetInstanceID();
|
||||
|
||||
|
||||
public override UIEffectContext context
|
||||
{
|
||||
@@ -115,11 +120,25 @@ namespace Coffee.UIEffects
|
||||
}
|
||||
}
|
||||
|
||||
public override RectTransform transitionRoot => useTargetTransform && isTargetInScene
|
||||
? target.transitionRoot
|
||||
: m_CustomRoot
|
||||
? m_CustomRoot
|
||||
: transform as RectTransform;
|
||||
public override RectTransform transitionRoot
|
||||
{
|
||||
get
|
||||
{
|
||||
if (preset && useTargetTransform && !m_CustomRoot && graphic && graphic.canvas)
|
||||
{
|
||||
return graphic.canvas.transform as RectTransform;
|
||||
}
|
||||
|
||||
if (useTargetTransform && isTargetInScene)
|
||||
{
|
||||
return target.transitionRoot;
|
||||
}
|
||||
|
||||
return m_CustomRoot
|
||||
? m_CustomRoot
|
||||
: transform as RectTransform;
|
||||
}
|
||||
}
|
||||
|
||||
private bool isTargetInScene => target && target.gameObject.scene.IsValid();
|
||||
|
||||
|
||||
@@ -152,6 +152,7 @@ Shader "Hidden/UI/Default (UIEffect)"
|
||||
{
|
||||
v2f IN = _fragInput;
|
||||
half4 color = (tex2D(_MainTex, uv) + _TextureSampleAdd);
|
||||
color.rgb *= IN.color.rgb;
|
||||
color.rgb *= color.a;
|
||||
return color;
|
||||
}
|
||||
@@ -170,7 +171,6 @@ Shader "Hidden/UI/Default (UIEffect)"
|
||||
|
||||
_fragInput = IN;
|
||||
half4 c = uieffect(IN.texcoord, IN.uvMask, IN.worldPosition);
|
||||
c.rgb *= IN.color.rgb;
|
||||
c *= IN.color.a;
|
||||
|
||||
#ifdef UNITY_UI_CLIP_RECT
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
"name": "com.coffee.ui-effect",
|
||||
"displayName": "UI Effect",
|
||||
"description": "UIEffect is an open-source package that allows you to intuitively apply rich UI effects directly from the Inspector or via code.\nCombine various filters, such as grayscale, blur, and dissolve, to decorate your UI with a unique visual style!",
|
||||
"version": "5.9.5",
|
||||
"version": "5.9.6",
|
||||
"unity": "2020.3",
|
||||
"license": "MIT",
|
||||
"repository": {
|
||||
|
||||
Reference in New Issue
Block a user