Right now we rebuild the command buffers every frame. This is relatively cheap since we re-use the buffers and makes managing them much simpler.
However, we do have the cost of iterating through all objects every frame then. This doesn't really need to happen, and we should really have a state system that manages if a mesh is dirty/needs to be updated.
At a minimum we need to update the UBO's of dirty entities every frame.
Right now we rebuild the command buffers every frame. This is relatively cheap since we re-use the buffers and makes managing them much simpler.
However, we do have the cost of iterating through all objects every frame then. This doesn't really need to happen, and we should really have a state system that manages if a mesh is dirty/needs to be updated.
At a minimum we need to update the UBO's of dirty entities every frame.