···235235enum multi_system_state
236236{
237237 /*!
238238- * Initial state and post stopping state.
238238+ * Invalid state, never used.
239239+ */
240240+ MULTI_SYSTEM_STATE_INVALID,
241241+242242+ /*!
243243+ * One of the initial states, the multi-client system compositor will
244244+ * make sure that its @ref xrt_compositor_native submits one frame.
245245+ *
246246+ * The session hasn't been started yet.
247247+ */
248248+ MULTI_SYSTEM_STATE_INIT_WARM_START,
249249+250250+ /*!
251251+ * One of the initial state and post stopping state.
239252 *
240253 * The multi-client system compositor has called @ref xrt_comp_end_session
241254 * on its @ref xrt_compositor_native.
+10
src/xrt/compositor/multi/comp_multi_system.c
···373373 enum xrt_view_type view_type = XRT_VIEW_TYPE_STEREO;
374374375375 switch (msc->sessions.state) {
376376+ case MULTI_SYSTEM_STATE_INIT_WARM_START:
377377+ U_LOG_I("Doing warm start, %u active app session(s).", (uint32_t)msc->sessions.active_count);
378378+379379+ // Produce at least one frame on init.
380380+ msc->sessions.state = MULTI_SYSTEM_STATE_STOPPING;
381381+ xrt_comp_begin_session(xc, view_type);
382382+ break;
383383+376384 case MULTI_SYSTEM_STATE_STOPPED:
377385 if (msc->sessions.active_count == 0) {
378386 break;
···387395 if (msc->sessions.active_count > 0) {
388396 break;
389397 }
398398+390399 U_LOG_I("Stopping main session, %u active app session(s).", (uint32_t)msc->sessions.active_count);
391400 msc->sessions.state = MULTI_SYSTEM_STATE_STOPPING;
392401 break;
···405414 xrt_comp_end_session(xc);
406415 break;
407416417417+ case MULTI_SYSTEM_STATE_INVALID:
408418 default:
409419 U_LOG_E("Got invalid state %u", msc->sessions.state);
410420 msc->sessions.state = MULTI_SYSTEM_STATE_STOPPING;