mirror of
https://github.com/love2d/love.git
synced 2026-08-16 00:02:12 +02:00
Fixed love.graphics.setShader with no arguments not properly restoring the default shader.
--HG-- branch : minor
This commit is contained in:
@@ -429,6 +429,14 @@ void Shader::attach(bool temporary)
|
||||
|
||||
void Shader::detach()
|
||||
{
|
||||
if (defaultShader)
|
||||
{
|
||||
if (current != defaultShader)
|
||||
defaultShader->attach();
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
if (current != nullptr)
|
||||
glUseProgram(0);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user