Skip to content
Flecs
v4.1
Search
Ctrl K
include
flecs
addons
cpp
mixins
app
mixin.inl
Go to the documentation of this file.
1
/**
2
* @file addons/cpp/mixins/app/mixin.inl
3
* @brief App world addon mixin.
4
*/
5
6
/**
7
* @ingroup cpp_addons_app
8
* @memberof flecs::world
9
*
10
* @{
11
*/
12
13
/** Return an app builder.
14
* The app builder is a convenience wrapper around a loop that runs
15
* world::progress(). An app allows for writing platform-agnostic code,
16
* as it provides hooks to modules for overtaking the main loop, which is
17
* required for frameworks like Emscripten.
18
*/
19
flecs::app_builder
app
() {
20
flecs::world_t
*w =
world_
;
21
world_
=
nullptr
;
// Take ownership
22
return
flecs::app_builder
(w);
23
}
24
25
/** @} */
flecs::world_t
ecs_world_t world_t
World type.
Definition
c_types.hpp:18
flecs::app_builder
App builder interface.
Definition
builder.hpp:19
flecs::world::world_
world_t * world_
Pointer to the underlying C world.
Definition
world.hpp:1009
flecs::world::app
flecs::app_builder app()
Return an app builder.
Definition
mixin.inl:19
Esc
↑
↓
to navigate
↵
to open
Esc
to close