MayaFlux 1.0.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches

◆ create_layer()

std::pair< std::shared_ptr< Layer >, std::shared_ptr< Context > > MayaFlux::Portal::Forma::internal::Atelier::create_layer ( const std::shared_ptr< Core::Window > &  window,
std::string  name 
)

Construct a Layer and a Context wired to window.

The Context is stored so its event coroutines outlive the call.

Definition at line 150 of file Atelier.cpp.

151{
152 auto layer = std::make_shared<Layer>();
153 auto ctx = std::make_shared<Context>(layer, window, *m_event_manager, std::move(name));
154
155 MayaFlux::store(ctx);
156
157 return { std::move(layer), std::move(ctx) };
158}
std::weak_ptr< Core::Window > window
Definition Picker.cpp:23
std::string name
Definition VKDevice.cpp:123
std::shared_ptr< Vruta::EventManager > m_event_manager
Definition Atelier.hpp:293
std::shared_ptr< T > store(std::shared_ptr< T > obj)
Transfer ownership of an existing object to the persistent store for process lifetime.
Definition Persist.hpp:28

References m_event_manager, name, MayaFlux::store(), and window.

Referenced by MayaFlux::Portal::Forma::create_layer(), create_surface(), MayaFlux::Portal::Forma::inspect(), MayaFlux::Portal::Forma::inspect(), MayaFlux::Portal::Forma::inspect(), MayaFlux::Portal::Forma::inspect(), MayaFlux::Portal::Forma::inspect_buffers(), MayaFlux::Portal::Forma::inspect_events(), MayaFlux::Portal::Forma::inspect_node_graph(), and MayaFlux::Portal::Forma::inspect_scheduler().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: