metal: implement depth/stencil state

This commit is contained in:
Alex Szpakowski
2020-06-14 21:14:56 -03:00
parent 9d2dca5740
commit 9aa9319eb5
9 changed files with 121 additions and 70 deletions
-10
View File
@@ -42,7 +42,6 @@ Shader::Shader(love::graphics::ShaderStage *vertex, love::graphics::ShaderStage
, program(0)
, builtinUniforms()
, builtinUniformInfo()
, builtinAttributes()
, lastPointSize(0.0f)
{
// load shader source and create program object
@@ -343,15 +342,6 @@ bool Shader::loadVolatile()
// Get all active uniform variables in this shader from OpenGL.
mapActiveUniforms();
for (int i = 0; i < int(ATTRIB_MAX_ENUM); i++)
{
const char *name = nullptr;
if (vertex::getConstant(BuiltinVertexAttribute(i), name))
builtinAttributes[i] = glGetAttribLocation(program, name);
else
builtinAttributes[i] = -1;
}
if (current == this)
{
// make sure glUseProgram gets called.