pub fn wait_for_render_thread_idle(&self) {
        if let Some(render_thread) = &self.render_thread {
            render_thread.wait_for_render_finish();
        }
    }
//TODO: We should probably implicitly do this when we do blocking waits for asset loads as the
// background processing to do the load may fetch resources that the render thread also fetches.
// However implementing this will require RendererLoadContext to have a ref to the render_thread
// to block. We probably also need to be the API such that we not only wait for the render
// thread to go idle, but also block it from starting again. When we do this we can remove the
// explicit wait_for_render_thread_idle() call from the demo.
We should probably implicitly do this when we do blocking waits for asset loads as the
background processing to do the load may fetch resources that the render thread also fetches.
However implementing this will require RendererLoadContext to have a ref to the render_thread
to block. We probably also need to be the API such that we not only wait for the render
thread to go idle, but also block it from starting again. When we do this we can remove the
explicit wait_for_render_thread_idle() call from the demo.
We should probably implicitly do this when we do blocking waits for asset loads as the background processing to do the load may fetch resources that the render thread also fetches . However implementing this will require RendererLoadContext to have a ref to the render_thread to block . We probably also need to be the API such that we not only wait for the render thread to go idle but also block it from starting again . When we do this we can remove the explicit wait_for_render_thread_idle () call from the demo .
pub fn wait_for_render_thread_idle(&self) {
        if let Some(render_thread) = &self.render_thread {
            render_thread.wait_for_render_finish();
        }
    }
pub fn wait_for_render_thread_idle ( & self ) { if let Some ( render_thread ) = & self . render_thread { render_thread . wait_for_render_finish ( ) ; } }
TODO: We should probably implicitly do this when we do blocking waits for asset loads as the
background processing to do the load may fetch resources that the render thread also fetches.
TODO : We should probably implicitly do this when we do blocking waits for asset loads as the background processing to do the load may fetch resources that the render thread also fetches .
&self
&self