-
-
Notifications
You must be signed in to change notification settings - Fork 273
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
UI batching is broken for SoftMaskable elements #76
Labels
Comments
Closed
As more or less expected, the preliminary fix was not sufficient; an additional hash by SoftMask is necessary (see pull request) |
@Arkarit |
mob-sakai
added a commit
that referenced
this issue
May 11, 2020
The rendering material is automatically generated. You don't need to pre-generate the material. The generated materials are cached and properly batched. Close #75, #76, #80 BREAKING CHANGE: The name of the custom SoftMaskable shader should be `<ShaderName> (SoftMaskable)`. For more information, see the "Support soft masks with your custom shaders" section of the README.
github-actions bot
pushed a commit
that referenced
this issue
May 11, 2020
# [1.0.0-preview.1](v0.10.0-preview.3...v1.0.0-preview.1) (2020-05-11) ### Bug Fixes * Unintentional material destruction ([bc28cc3](bc28cc3)) ### change * change namespace ([7b740a7](7b740a7)) ### Features * support graphic connector ([b603646](b603646)), closes [#75](#75) [#76](#76) [#80](#80) ### BREAKING CHANGES * If your code contained the SoftMask API, it would fail to compile. Please change the namespace from `Coffee.UIExtensions` to `Coffee.UISoftMask`. * The name of the custom SoftMaskable shader should be `<ShaderName> (SoftMaskable)`. For more information, see the "Support soft masks with your custom shaders" section of the README.
mob-sakai
added a commit
that referenced
this issue
May 11, 2020
The rendering material is automatically generated. You don't need to pre-generate the material. The generated materials are cached and properly batched. Close #75, #76, #80 BREAKING CHANGE: The name of the custom SoftMaskable shader should be `<ShaderName> (SoftMaskable)`. For more information, see the ‘Support soft masks with your custom shaders’ section of the README.
github-actions bot
pushed a commit
that referenced
this issue
May 11, 2020
# [1.0.0-preview.1](v0.10.0-preview.3...v1.0.0-preview.1) (2020-05-11) ### Bug Fixes * Unintentional material destruction ([0733243](0733243)) ### change * change namespace ([6a1a928](6a1a928)) ### Features * support graphic connector ([760f715](760f715)), closes [#75](#75) [#76](#76) [#80](#80) ### BREAKING CHANGES * If your code contained the SoftMask API, it would fail to compile. Please change the namespace from `Coffee.UIExtensions` to `Coffee.UISoftMask`. * The name of the custom SoftMaskable shader should be `<ShaderName> (SoftMaskable)`. For more information, see the ‘Support soft masks with your custom shaders’ section of the README.
mob-sakai
added a commit
that referenced
this issue
May 11, 2020
The rendering material is automatically generated. You don't need to pre-generate the material. The generated materials are cached and properly batched. Close #75, #76, #80 BREAKING CHANGE: The name of the custom SoftMaskable shader must be changed. For more information, see the ‘Support soft masks with your custom shaders’ section of the README.
github-actions bot
pushed a commit
that referenced
this issue
May 11, 2020
# [1.0.0-preview.1](v0.10.0-preview.3...v1.0.0-preview.1) (2020-05-11) ### Bug Fixes * Unintentional material destruction ([ab71747](ab71747)) ### change * change namespace ([ad59523](ad59523)) ### Features * support graphic connector ([bd1ac08](bd1ac08)), closes [#75](#75) [#76](#76) [#80](#80) ### BREAKING CHANGES * If your code contained the SoftMask API, it would fail to compile. Please change the namespace from `Coffee.UIExtensions` to `Coffee.UISoftMask`. * The name of the custom SoftMaskable shader must be changed. For more information, see the ‘Support soft masks with your custom shaders’ section of the README.
github-actions bot
pushed a commit
that referenced
this issue
May 11, 2020
# [1.0.0-preview.1](v0.10.0-preview.3...v1.0.0-preview.1) (2020-05-11) ### Bug Fixes * Unintentional material destruction ([ab71747](ab71747)) ### change * change namespace ([ad59523](ad59523)) ### Features * support graphic connector ([bd1ac08](bd1ac08)), closes [#75](#75) [#76](#76) [#80](#80) ### BREAKING CHANGES * If your code contained the SoftMask API, it would fail to compile. Please change the namespace from `Coffee.UIExtensions` to `Coffee.UISoftMask`. * The name of the custom SoftMaskable shader must be changed. For more information, see the ‘Support soft masks with your custom shaders’ section of the README.
github-actions bot
pushed a commit
that referenced
this issue
May 11, 2020
# [1.0.0-preview.1](v0.10.0-preview.3...v1.0.0-preview.1) (2020-05-11) ### Bug Fixes * Unintentional material destruction ([ab71747](ab71747)) ### change * change namespace ([ad59523](ad59523)) ### Features * support graphic connector ([bd1ac08](bd1ac08)), closes [#75](#75) [#76](#76) [#80](#80) ### BREAKING CHANGES * If your code contained the SoftMask API, it would fail to compile. Please change the namespace from to . * The name of the custom SoftMaskable shader must be changed. For more information, see the ‘Support soft masks with your custom shaders’ section of the README.
mob-sakai
added a commit
that referenced
this issue
May 11, 2020
The rendering material is automatically generated. You don't need to pre-generate the material. The generated materials are cached and properly batched. Close #75, close #76, close #80 BREAKING CHANGE: The name of the custom SoftMaskable shader must be changed. For more information, see the ‘Support soft masks with your custom shaders’ section of the README.
github-actions bot
pushed a commit
that referenced
this issue
May 11, 2020
# [1.0.0-preview.1](v0.10.0-preview.3...v1.0.0-preview.1) (2020-05-11) ### Bug Fixes * Unintentional material destruction ([bf17b19](bf17b19)) ### change * change namespace ([0347b04](0347b04)) ### Features * support graphic connector ([3451521](3451521)), closes [#75](#75) [#76](#76) [#80](#80) ### BREAKING CHANGES * If your code contained the SoftMask API, it would fail to compile. Please change the namespace from `Coffee.UIExtensions` to `Coffee.UISoftMask`. * The name of the custom SoftMaskable shader must be changed. For more information, see the ‘Support soft masks with your custom shaders’ section of the README.
github-actions bot
pushed a commit
that referenced
this issue
May 11, 2020
# [1.0.0-preview.1](v0.10.0-preview.3...v1.0.0-preview.1) (2020-05-11) ### Bug Fixes * Unintentional material destruction ([bf17b19](bf17b19)) ### change * change namespace ([0347b04](0347b04)) ### Features * support graphic connector ([3451521](3451521)), closes [#75](#75) [#76](#76) [#80](#80) ### BREAKING CHANGES * If your code contained the SoftMask API, it would fail to compile. Please change the namespace from to . * The name of the custom SoftMaskable shader must be changed. For more information, see the ‘Support soft masks with your custom shaders’ section of the README.
🎉 This issue has been resolved in version 1.0.0-preview.1 🎉 The release is available on:
Your semantic-release bot 📦🚀 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Describe the bug
SoftMaskable applies a cloned, modified unique material to each Graphic it belongs to. This breaks UI batching for all SoftMaskable elements completely.
To Reproduce
Steps to reproduce the behavior:
Also, the issue can be examined in the Profiler (UI/Render, "Batch breaking reason: Different material instance")
Environment (please complete the following information):
Additional context
The reason seems to be in SoftMaskable.GetModifiedMaterial().
For testing purposes, I simply added a dict to store already modified materials, which seems to fix the issue at first glance (but as I am not too deep into it, some additional checks might be necessary).
See attached patch.
SoftMaskForUGUI-test-fix-batching.txt
The text was updated successfully, but these errors were encountered: