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
I added shaders to my game recently and to ease in the new feature I decided to use your passthrough shader from the tutorial here. After adding it, I noticed anything being drawn by an IMDraw was black instead of the color it was supposed to be. Sprites and the Canvas clear color all show up as normal, but my IMDraw borders around buttons and simplistic progress bar appear as black.
Two causes come to mind.
There is no "texture" for IMDraw things for the shader to reference.
I'm drawing everything to a canvas, and then drawing the canvas to the window.
Number 1 makes a lot of sense if you look at the source, but I don't think I know enough about shaders yet to know what to do instead. Number 2 is something I read can enable a lot of advanced things but I'm still wrapping my head around the details so I admit this might be a side effect of that.
I don't think this is a bug in pixel, just in my understanding. How should I write my shaders to work with IMDraw?
I added shaders to my game recently and to ease in the new feature I decided to use your passthrough shader from the tutorial here. After adding it, I noticed anything being drawn by an IMDraw was black instead of the color it was supposed to be. Sprites and the Canvas clear color all show up as normal, but my IMDraw borders around buttons and simplistic progress bar appear as black.
Two causes come to mind.
Number 1 makes a lot of sense if you look at the source, but I don't think I know enough about shaders yet to know what to do instead. Number 2 is something I read can enable a lot of advanced things but I'm still wrapping my head around the details so I admit this might be a side effect of that.
I don't think this is a bug in pixel, just in my understanding. How should I write my shaders to work with IMDraw?
Mac Big Sur x64
Pixel v0.10
Go 1.17.7
Original issue: faiface/pixel#305
The text was updated successfully, but these errors were encountered: