Set texture unit 0 in base class

This commit is contained in:
Riyyi
2021-01-11 16:03:31 +01:00
parent b8438ad3e7
commit 2d54a8372f
+3 -3
View File
@@ -47,6 +47,9 @@ namespace Inferno {
uint32_t gpuTextureUnitCount = RenderCommand::textureUnitAmount();
m_supportedTextureUnitPerBatch = std::min(constTextureUnitCount, gpuTextureUnitCount);
// Texture unit 0 is reserved for no texture
m_textureUnits[0] = nullptr;
// Create texture unit samplers
int32_t samplers[textureUnitPerBatch];
for (uint32_t i = 0; i < textureUnitPerBatch; i++) {
@@ -136,9 +139,6 @@ namespace Inferno {
m_vertexPositions[2] = { 0.5f, 0.5f, 0.0f, 1.0f };
m_vertexPositions[3] = { -0.5f, 0.5f, 0.0f, 1.0f };
// Texture unit 0 is reserved for no texture
m_textureUnits[0] = nullptr;
// GPU
// -----------------------------------------