|
MayaFlux 0.5.0
Digital-First Multimedia Processing Framework
|
| Mapped< T > MayaFlux::Portal::Forma::create | ( | Surface & | surface, |
| Geometry::Form< T > | form, | ||
| T | initial, | ||
| std::function< float(T)> | project = {} |
||
| ) |
Realize a Form on surface.
Builds the buffer at the Form's capacity and topology, registers the element, syncs so the geometry function's bounds_hint and contains reach the Layer before the first frame, then runs the Form's interaction wiring.
A bare GeometryFn converts to a Form, so this also serves as the simplest element construction path for a caller's own geometry.
| T | MappedState value type. |
| surface | Canvas to register on. |
| form | Geometry, topology, capacity, and interaction. |
| initial | Starting value written into MappedState. |
| project | Optional T to float projection for outbound readers. |
Definition at line 277 of file Forma.hpp.