You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ShaderRenderer is currently a big monolithic class. Maybe it makes sense to incorporate a more composable / modular design, so that future additional uniforms are easier to add.
Example: a GyroscopeUniformComponent instead of writing it into the ShaderRenderer class. This also follows SRP (Single Responsibility Principle). I'll look more into it, but maybe a possible UniformComponent interface could be like following:
True, ShaderRenderer has grown quite big over the years and refactoring it may really be beneficial.So, if you want, have a try 😉 I would sure appreciate it!I just have to add that I'm a big fan of keeping things as simple as possible (less complex, not easy as possible), what sometimes conflicts a bit with textbook structures. But, of course, these structures have their place and maybe it's long overdue to finally use some of these well established patterns here.
You are right, keeping it as simple as possible is really important. Adding abstractions just for no reason will only add complexity. I'll try some ideas, but most ideas I had added more state / complexity in hindsight, so I don't think that's worth merging
ShaderRenderer
is currently a big monolithic class. Maybe it makes sense to incorporate a more composable / modular design, so that future additional uniforms are easier to add.Example: a
GyroscopeUniformComponent
instead of writing it into theShaderRenderer
class. This also follows SRP (Single Responsibility Principle). I'll look more into it, but maybe a possibleUniformComponent
interface could be like following:The text was updated successfully, but these errors were encountered: