Compare commits

...

8 Commits

Author SHA1 Message Date
semantic-release-bot 88261e2af0 chore(release): 5.8.5 [skip ci]
## [5.8.5](https://github.com/mob-sakai/UIEffect/compare/5.8.4...5.8.5) (2025-05-22)

### Bug Fixes

* skip processing when graphic is invalid ([5cd48a4](https://github.com/mob-sakai/UIEffect/commit/5cd48a463309270ec3d6501bde2add9944bbaf02))
* TextMeshPro strikethrough and underline not displaying ([68ebae2](https://github.com/mob-sakai/UIEffect/commit/68ebae28e02045cb45996bf5b77d7d93d2f0ca82)), closes [#344](https://github.com/mob-sakai/UIEffect/issues/344)
* TMP SubMeshUI generates overhead every frame (since 5.6.0) ([791d867](https://github.com/mob-sakai/UIEffect/commit/791d8670761902466d81412d832cddf013cd28cd)), closes [#343](https://github.com/mob-sakai/UIEffect/issues/343) [#345](https://github.com/mob-sakai/UIEffect/issues/345)
2025-05-22 11:14:57 +00:00
mob-sakai 791d867076 fix: TMP SubMeshUI generates overhead every frame (since 5.6.0)
close #343, close #345
2025-05-22 19:48:34 +09:00
mob-sakai 68ebae28e0 fix: TextMeshPro strikethrough and underline not displaying
close #344
2025-05-22 19:48:34 +09:00
mob-sakai 5cd48a4633 fix: skip processing when graphic is invalid 2025-05-22 19:48:34 +09:00
semantic-release-bot 3ff52e4735 chore(release): 5.8.4 [skip ci]
## [5.8.4](https://github.com/mob-sakai/UIEffect/compare/5.8.3...5.8.4) (2025-04-30)

### Bug Fixes

* NRE while canvas is disabled ([a3773e3](https://github.com/mob-sakai/UIEffect/commit/a3773e33028c60517fb4e6c534f6280194df8e64)), closes [#342](https://github.com/mob-sakai/UIEffect/issues/342)
2025-04-30 22:53:37 +00:00
mob-sakai a3773e3302 fix: NRE while canvas is disabled
close #342
2025-05-01 07:53:04 +09:00
semantic-release-bot 5a9f335bf8 chore(release): 5.8.3 [skip ci]
## [5.8.3](https://github.com/mob-sakai/UIEffect/compare/5.8.2...5.8.3) (2025-04-30)

### Bug Fixes

* the alpha of the gradation color and gradient was being ignored ([3807e4c](https://github.com/mob-sakai/UIEffect/commit/3807e4c69aefaef04b2245522e7c5085ccc65a36)), closes [#341](https://github.com/mob-sakai/UIEffect/issues/341)
2025-04-30 09:49:34 +00:00
mob-sakai 3807e4c69a fix: the alpha of the gradation color and gradient was being ignored
close #341
2025-04-30 18:48:27 +09:00
5 changed files with 37 additions and 7 deletions
+23
View File
@@ -1,3 +1,26 @@
## [5.8.5](https://github.com/mob-sakai/UIEffect/compare/5.8.4...5.8.5) (2025-05-22)
### Bug Fixes
* skip processing when graphic is invalid ([5cd48a4](https://github.com/mob-sakai/UIEffect/commit/5cd48a463309270ec3d6501bde2add9944bbaf02))
* TextMeshPro strikethrough and underline not displaying ([68ebae2](https://github.com/mob-sakai/UIEffect/commit/68ebae28e02045cb45996bf5b77d7d93d2f0ca82)), closes [#344](https://github.com/mob-sakai/UIEffect/issues/344)
* TMP SubMeshUI generates overhead every frame (since 5.6.0) ([791d867](https://github.com/mob-sakai/UIEffect/commit/791d8670761902466d81412d832cddf013cd28cd)), closes [#343](https://github.com/mob-sakai/UIEffect/issues/343) [#345](https://github.com/mob-sakai/UIEffect/issues/345)
## [5.8.4](https://github.com/mob-sakai/UIEffect/compare/5.8.3...5.8.4) (2025-04-30)
### Bug Fixes
* NRE while canvas is disabled ([a3773e3](https://github.com/mob-sakai/UIEffect/commit/a3773e33028c60517fb4e6c534f6280194df8e64)), closes [#342](https://github.com/mob-sakai/UIEffect/issues/342)
## [5.8.3](https://github.com/mob-sakai/UIEffect/compare/5.8.2...5.8.3) (2025-04-30)
### Bug Fixes
* the alpha of the gradation color and gradient was being ignored ([3807e4c](https://github.com/mob-sakai/UIEffect/commit/3807e4c69aefaef04b2245522e7c5085ccc65a36)), closes [#341](https://github.com/mob-sakai/UIEffect/issues/341)
## [5.8.2](https://github.com/mob-sakai/UIEffect/compare/5.8.1...5.8.2) (2025-04-23)
+6 -1
View File
@@ -64,6 +64,7 @@ namespace Coffee.UIEffects
protected override void OnEnable()
{
_canModifyMesh = true;
_onBeforeCanvasRebuild ??= OnBeforeCanvasRebuild;
_onAfterCanvasRebuild ??= OnAfterCanvasRebuild;
UIExtraCallbacks.onBeforeCanvasRebuild += _onBeforeCanvasRebuild;
@@ -99,15 +100,17 @@ namespace Coffee.UIEffects
protected virtual void OnBeforeCanvasRebuild()
{
// If the mesh is not modified in the previous frame, try to modify it if possible.
if (!_canModifyMesh && CanModifyMesh())
{
_canModifyMesh = true;
SetVerticesDirty();
}
}
protected virtual void OnAfterCanvasRebuild()
{
if (!_material || !graphic || context == null) return;
if (!_material || !graphic || !graphic.canvas || context == null) return;
context.UpdateViewMatrix(GetCurrentMaterial(), transitionRoot, graphic.canvas.rootCanvas);
}
@@ -129,6 +132,8 @@ namespace Coffee.UIEffects
private bool CanModifyMesh()
{
if (!graphic || !graphic.isActiveAndEnabled) return false;
// The transitionRoot is same as the transform => true.
var root = transitionRoot;
if (transform == root) return true;
+1 -1
View File
@@ -226,7 +226,7 @@ namespace Coffee.UIEffects
{
var meshInfo = textMeshProUGUI.textInfo.meshInfo[i];
s_VertexHelper.Clear();
meshInfo.mesh.CopyTo(s_VertexHelper, meshInfo.vertexCount, meshInfo.vertexCount * 6 / 4);
meshInfo.mesh.CopyTo(s_VertexHelper);
if (i == 0)
{
foreach (var modifier in modifiers)
+6 -4
View File
@@ -592,26 +592,28 @@ half4 apply_gradation_filter(const half4 inColor, const float2 uvGrad)
if (mode == 1) // Color.Multiply
{
color.rgb = color.rgb * factor.rgb;
color *= factor.a;
}
else if (mode == 2) // Color.Additive
{
color.rgb = color.rgb + factor.rgb * color.a;
color.rgb = color.rgb + factor.rgb * color.a * factor.a;
}
else if (mode == 3) // Color.Subtractive
{
color.rgb = color.rgb - factor.rgb * color.a;
color.rgb = color.rgb - factor.rgb * color.a * factor.a;
}
else if (mode == 4) // Color.Replace
{
color.rgb = factor.rgb * color.a;
color *= factor.a;
}
else if (mode == 5) // Color.MultiplyLuminance
{
color.rgb = (1 + Luminance(color.rgb)) * factor.rgb / 2 * color.a;
color.rgb = (1 + Luminance(color.rgb)) * factor.rgb * factor.a / 2 * color.a;
}
else if (mode == 6) // Color.MultiplyAdditive
{
color.rgb = color.rgb * (1 + factor.rgb);
color.rgb = color.rgb * (1 + factor.rgb * factor.a);
}
if (0 < mode)
+1 -1
View File
@@ -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.8.2",
"version": "5.8.5",
"unity": "2020.3",
"license": "MIT",
"repository": {