TextureProgressBars Should Allow For Individual Material/Shaders On Each Texture #11988
TheNichKing
started this conversation in
2D
Replies: 1 comment
-
Each TextureProgressBar node is its own CanvasItem. Each CanvasItem can only have one shader applied at a time, so this isn't technically possible to my knowledge. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hello,
I've run into this issue a few times since Godot 3 but it would be really helpful if TextureProgressBars allowed you to set an individual shader/material on each texture. Right now, the shader/material provided by CanvasItem applies to the entire bar and all of its textures.
I've searched online and there are a great number of various levels of hacky solutions to accomplish these kinds of effects. Namely, a lot of people seem to be interested in applying a shader only to the progress texture alone. Many solutions I've seen either require the use of multiple Control/TextureRect/TextureProgressBar nodes or an entirely custom written solution that replicates most of the features of a TextureProgressBar just to expose the textures directly to the draw renderer, which seems inelegant and prone to a lot of bugs and issues to me.
I think having the ability to apply custom shaders/materials to each texture in the TextureProgressBar would make it a lot easier to make higher graphical fidelity texture bars. As an example, I could have a shader that gives a particular pattern to the progress texture while having another shader that gives a shine effect to the over or under textures. Given that display bars are a relatively common feature in most games (health bars, timer bars, load bars, progress bars, etc) and the number of people I've seen posting various forms of solutions, I think this would be a highly beneficial feature to the community.
Beta Was this translation helpful? Give feedback.
All reactions