OpenGL: Implement buffers

This commit is contained in:
Lynix
2020-04-26 18:20:36 +02:00
parent 494801282d
commit 0b05feb7e3
13 changed files with 213 additions and 209 deletions

View File

@@ -37,6 +37,15 @@ namespace Nz::GL
return m_supportedExtensions.find(extension) != m_supportedExtensions.end();
}
inline void Context::NotifyBufferDestruction(GLuint buffer) const
{
for (GLuint& boundBuffer : m_state.bufferTargets)
{
if (boundBuffer == buffer)
boundBuffer = 0;
}
}
inline void Context::NotifySamplerDestruction(GLuint sampler) const
{
for (auto& unit : m_state.textureUnits)