Palm-Studios / sh3redux

SILENT HILL 3 Engine Remake in OpenGL and C++
GNU General Public License v3.0
162 stars 16 forks source link

Tweaked GL Program interface #97

Closed Quaker762 closed 7 years ago

Quaker762 commented 7 years ago

Now allows the programID to be accessed by the caller. Useful form interfacing with a GLSL program from C++. Also adds an interface to find uniform locations from the currently active GL Program.

z33ky commented 7 years ago

Ah, we'll just leave it open for now. The OpenGL VAO and VBO abstraction should land soon ;)

Quaker762 commented 7 years ago

@z33ky Guess I'll need to rebase this yes?

z33ky commented 7 years ago

Yes.

I was thinking of having just SetUniform(name, val), but it might be better to have the separation by name for int and float. The Vec and Mat postfixes then make sense for consistency.

Quaker762 commented 7 years ago

I was thinking of having just SetUniform(name, val), but it might be better to have the separation by name for int and float. The Vec and Mat postfixes then make sense for consistency.

So we'll keep it as is then yeah?? It'll definitely help reduce type confusion, as god knows what kind of problems we might run into if we accidentally get/set the wrong type in the shader.