Fixed validation error caused by deleting empty batches

This commit is contained in:
Kah Wei 2022-11-16 19:23:26 +08:00
parent f0c09817ce
commit c5bca4111b
2 changed files with 4 additions and 4 deletions

View File

@ -69,9 +69,9 @@ namespace SHADE
batch->Remove(renderable); batch->Remove(renderable);
// If batch is empty, remove batch // TODO: If the pipeline is unloaded, we remove the batch
if (batch->IsEmpty()) /*if (batch->IsEmpty() && !batch->GetPipeline())
batches.erase(batch); batches.erase(batch);*/
} }
void SHSuperBatch::Clear() noexcept void SHSuperBatch::Clear() noexcept