cginternals / cginternals/globjects
Add support for shader subroutines
Open
decision required
feature request
- Dominant language
- C++
- Stars
- 563
- Forks
- 59
- PR merge metrics
- No merged PRs in 30d
Description
See https://www.khronos.org/opengl/wiki/Shader_Subroutine
`glUniformSubroutinesuiv` must be called after every call to `glUseProgram` to (re-)activate subroutines. Since subroutines have not much in common with normal uniforms, I suggest a special integration: store a list of selected subroutine indices by shader type inside `Program`, expose corresponding get/set functions and call `glUniformSubroutinesuiv` in `Program::use()` if the list is non-empty. (Plus the same for `ProgramPipeline`)
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.