Metal platform fixes

This commit is contained in:
Jack Andersen
2016-07-31 10:25:02 -10:00
parent 0ee5944387
commit 2ec943f0b2
5 changed files with 10 additions and 23 deletions

View File

@@ -621,10 +621,6 @@ struct MetalShaderDataBinding : IShaderDataBinding
}
for (size_t i=0 ; i<texCount ; ++i)
{
#ifndef NDEBUG
if (!texs[i])
Log.report(logvisor::Fatal, "null texture %d provided to newShaderDataBinding", int(i));
#endif
m_texs[i] = texs[i];
}
}
@@ -653,7 +649,8 @@ struct MetalShaderDataBinding : IShaderDataBinding
[enc setVertexBuffer:GetBufferGPUResource(m_ubufs[i], b) offset:0 atIndex:i+2];
}
for (size_t i=0 ; i<m_texCount ; ++i)
[enc setFragmentTexture:GetTextureGPUResource(m_texs[i], b) atIndex:i];
if (m_texs[i])
[enc setFragmentTexture:GetTextureGPUResource(m_texs[i], b) atIndex:i];
}
};