Remove GL Program

Hello,

Is there a way to remove a GL Program shader being used by a Sprite, in order to make it go back to the original state?
I’ve tried setting the GLProgram e GLProgramState to null, but the game crashes when that happens.

Thank you!

sprite->setGLProgramState(
   GLProgramState::getOrCreateWithGLProgramName(
      GLProgram::SHADER_NAME_POSITION_TEXTURE_COLOR_NO_MVP
   )
);
7 Likes

Works like a charm!