I am finally able to convert my engine over to Monogame after waiting years for VertexBufferBindings to be added so thank you so much for that! I am having problems with my light rendering shader. This of course works as intended in XNA 4.0 but it almost seems like the shader has no data when it’s actually running on the card.
Pausing the code while running lets me peak at the data currently in the parameters and they are correct. I have 1 light enabled and it has a range of 10, a color of blue, and is located at 0,2,0.
(22-25)
The problem I am having is that it appears that all the array entries are actually null/0 even though the debugger says they have the correct information. Light_Enabled always equals false, Light_Range always equals 0 etc. Even if I tell my PS to return Light_Color[0], it returns 0,0,0,0.
I am using MonoGame 3.6 on a GTX 1070 with the latest drivers. Windows DirectX application. PS 5_0, VS 5_0
Just to make sure I wasn’t going crazy, I removed the array and just made it 1 standard light. It works correctly.
Yes! That got it. That’s how I did it in XNA but Monogame removed the option to send a boolean array, forcing the change. I’ll adopt your style of sending an int for the number of lights to actually draw. Thanks so much!