Exemple #1
0
bool check_events() {
    bool true_value = true;
    if (flag_needs_recreate_swapchain.compare_exchange_weak(true_value, false)) {
        graphics::render3d::resources::create_pipeline();
    }
    return true;
}
void
OSLockScheduler()
{
   bool locked = false;

   while (!gSchedulerLock.compare_exchange_weak(locked, true, std::memory_order_acquire)) {
      locked = false;
   }
}