FlushRenderingCommands

Waits for the rendering thread to finish executing all pending rendering commands.