Built-in event identifiers and payloads published through the generic extension
event transport in `
| Namespace: | dmEngine |
| Include: | #include <dmsdk/engine/engine_event_gen.hpp> |
| CONSTANTS | |
|---|---|
| ENGINE_STATE_EVENT | engine state notification |
| ENGINE_WINDOW_EVENT | engine window notification |
| EVENT_STATE | engine state notification |
| EVENT_WINDOW | engine window notification |
| ENUMS | |
|---|---|
| EngineState | engine state notification kind |
| EngineWindowEventType | window notification kind |
| State | engine state notification kind |
| WindowEventType | window notification kind |
| STRUCTS | |
|---|---|
| struct EngineStateEvent | engine state event payload |
| struct EngineWindowEvent | engine window event payload |
| struct StateEvent | engine state event payload |
| struct WindowEvent | engine window event payload |
| MACROS | |
|---|---|
| ENGINE_WINDOW_EVENT_INITIALIZER () | initialize a window event |
| ENGINE_WINDOW_EVENT_RESIZED_INITIALIZER () | initialize a window resize event |
TYPE
struct EngineStateEventPayload for ENGINE_STATE_EVENT with data_size equal to sizeof(EngineStateEvent). Obtain the source engine from the extension context registry using ENGINE_CONTEXT_NAME.
MEMBERS
EngineState |
m_State |
notification being delivered |
TYPE
struct EngineWindowEventPayload for ENGINE_WINDOW_EVENT with data_size equal to sizeof(EngineWindowEvent). m_Type selects the valid union member. Only ENGINE_WINDOW_EVENT_RESIZED has event-specific data: m_Data.m_Resized contains the physical framebuffer dimensions. Do not read that member for other notification types. Resize delivery follows the existing window state updates and notifications, once per native resize callback with no initial-size replay. Window events may arrive before engine Initialize; m_Window can be null during early startup. Obtain the source engine from the extension context registry using ENGINE_CONTEXT_NAME.
MEMBERS
HWindow |
m_Window |
borrowed source window, or null if not yet available |
EngineWindowEventType |
m_Type |
notification selecting the valid payload |
uint32_t |
m_Data.m_Resized.m_Width |
physical framebuffer width; valid only for ENGINE_WINDOW_EVENT_RESIZED |
uint32_t |
m_Data.m_Resized.m_Height |
physical framebuffer height; valid only for ENGINE_WINDOW_EVENT_RESIZED |
TYPE
struct StateEventPayload for EVENT_STATE with data_size equal to sizeof(StateEvent). Obtain the source engine from the extension context registry using ENGINE_CONTEXT_NAME.
MEMBERS
State |
m_State |
notification being delivered |
TYPE
struct WindowEventPayload for EVENT_WINDOW with data_size equal to sizeof(WindowEvent). m_Type selects the valid union member. Only WINDOW_EVENT_RESIZED has event-specific data: m_Data.m_Resized contains the physical framebuffer dimensions. Do not read that member for other notification types. Resize delivery follows the existing window state updates and notifications, once per native resize callback with no initial-size replay. Window events may arrive before engine Initialize; m_Window can be null during early startup. Obtain the source engine from the extension context registry using ENGINE_CONTEXT_NAME.
MEMBERS
HWindow |
m_Window |
borrowed source window, or null if not yet available |
WindowEventType |
m_Type |
notification selecting the valid payload |
uint32_t |
m_Data.m_Resized.m_Width |
physical framebuffer width; valid only for WINDOW_EVENT_RESIZED |
uint32_t |
m_Data.m_Resized.m_Height |
physical framebuffer height; valid only for WINDOW_EVENT_RESIZED |
Identifies the initialization or deletion notification in EngineStateEvent.
ENGINE_STATE_INITIALIZED |
Successful engine initialization has completed. |
ENGINE_STATE_DELETE_BEGIN |
Engine deletion begins, before collections and systems are torn down. Also delivered after initialization failure if AppInitialize succeeded. |
Identifies the active payload in EngineWindowEvent.
ENGINE_WINDOW_EVENT_RESIZED |
Resize notification. Read physical dimensions from m_Data.m_Resized. |
ENGINE_WINDOW_EVENT_MINIMIZED |
The window was minimized; not a hide notification. |
ENGINE_WINDOW_EVENT_RESTORED |
The window was restored from minimization; not a show notification. |
ENGINE_WINDOW_EVENT_FOCUS_GAINED |
The window or app screen gained focus. |
ENGINE_WINDOW_EVENT_FOCUS_LOST |
The window or app screen lost focus. |
Identifies the initialization or deletion notification in StateEvent.
STATE_INITIALIZED |
Successful engine initialization has completed. |
STATE_DELETE_BEGIN |
Engine deletion begins, before collections and systems are torn down. Also delivered after initialization failure if AppInitialize succeeded. |
Identifies the active payload in WindowEvent.
WINDOW_EVENT_RESIZED |
Resize notification. Read physical dimensions from m_Data.m_Resized. |
WINDOW_EVENT_MINIMIZED |
The window was minimized; not a hide notification. |
WINDOW_EVENT_RESTORED |
The window was restored from minimization; not a show notification. |
WINDOW_EVENT_FOCUS_GAINED |
The window or app screen gained focus. |
WINDOW_EVENT_FOCUS_LOST |
The window or app screen lost focus. |
Brace initializer for an EngineWindowEvent declaration, with zeroed event data. Each argument is evaluated once. Available with the same name in C and C++.
EXAMPLES
EngineWindowEvent event = ENGINE_WINDOW_EVENT_INITIALIZER(window, ENGINE_WINDOW_EVENT_FOCUS_GAINED);
Brace initializer for an EngineWindowEvent declaration with type ENGINE_WINDOW_EVENT_RESIZED. Each argument is evaluated once. Available with the same name in C and C++.
EXAMPLES
EngineWindowEvent event = ENGINE_WINDOW_EVENT_RESIZED_INITIALIZER(window, 800, 600);