mirror of
https://github.com/Lime3DS/Lime3DS.git
synced 2024-11-30 13:24:16 +01:00
video_core: gl_shader_manager: Only set shader samplers on fragment shader.
- Avoids unnecessary uniform errors.
This commit is contained in:
parent
3b2b9282d3
commit
e028eb91c0
@ -177,9 +177,12 @@ public:
|
|||||||
OGLProgram& program = boost::get<OGLProgram>(shader_or_program);
|
OGLProgram& program = boost::get<OGLProgram>(shader_or_program);
|
||||||
program.Create(true, {shader.handle});
|
program.Create(true, {shader.handle});
|
||||||
SetShaderUniformBlockBindings(program.handle);
|
SetShaderUniformBlockBindings(program.handle);
|
||||||
|
|
||||||
|
if (type == GL_FRAGMENT_SHADER) {
|
||||||
SetShaderSamplerBindings(program.handle);
|
SetShaderSamplerBindings(program.handle);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
GLuint GetHandle() const {
|
GLuint GetHandle() const {
|
||||||
if (shader_or_program.which() == 0) {
|
if (shader_or_program.which() == 0) {
|
||||||
|
Loading…
Reference in New Issue
Block a user