haskell-opengl / OpenGL

Haskell bindings to OpenGL
http://www.haskell.org/haskellwiki/OpenGL
BSD 3-Clause "New" or "Revised" License
147 stars 26 forks source link

Add missing API abstractions #93

Closed ernestask closed 1 year ago

ernestask commented 2 years ago

Currently, there is no convenient way to specialize shaders, so this commit adds a way to do so via a SettableStateVar.

Fixes https://github.com/haskell-opengl/OpenGL/issues/92

ernestask commented 2 years ago

@svenpanne, do you think the data constructors should be hidden in general? If the one for Shader wasn’t hidden, it would still be possible to go through OpenGLRaw to achieve things.

ernestask commented 2 years ago

So I’ll implement additional API in the meantime, since I find myself in need.