fixing put pixel, adding scene change checker

This commit is contained in:
Kbz-8
2024-10-21 01:48:01 +02:00
parent 59455495b6
commit c7484b771f
28 changed files with 302 additions and 201 deletions

View File

@@ -19,8 +19,12 @@ namespace mlx
#endif
texture.Clear(VK_NULL_HANDLE, Vec4f{ 0.0f });
}
m_textures.back().SetPixel(x, y, color);
return (insert_new_texture ? &m_textures.back() : nullptr);
if(!m_textures.empty())
{
m_textures.back().SetPixel(x, y, color);
return (insert_new_texture ? &m_textures.back() : nullptr);
}
return nullptr;
}
void PutPixelManager::ResetRenderData()