one stream of the device's desc while it is in use: the ring its clients share, the format they agreed on, and the session its dx::stream::control counts. The ring is allocated once (alloc()/free(), never across a start/stop cycle) and reset by its host alone at a session start - a participant mapping another's ring replaces the run hook and anchors a cursor instead. Bus streams derive from this one: a pipe, a shared memory ring, the kernel's mapping.
More...
|
| template<typename channel_t> |
| stream & | attach (channel_t **[2], const std::vector< bool > &, direction::direction) |
| | the pin passes its own direction: a stream shared by two pins carries none of its own
|
| virtual float | encoder (dx::stream::encoder::index::type, unsigned int) const |
| virtual bool | encoder (dx::stream::encoder::index::type, unsigned int, float) |
| void | exception (const class exception &exception, bool filtered=false) const noexcept override |
| void | flush () |
| void | info (std::ostream &os) noexcept override |
| virtual void | initialize () |
| void | launch () override |
| | operator circular_t * () const noexcept |
| circular_t * | operator-> () const noexcept |
| virtual os_result | status () noexcept |
| | stream (device_t &device, const decltype(id)&id, const descdesc &descdesc) |
| | creates circular streaming backing store and frame buffers
|
| virtual uint8_t | submit (dx::stream::encoder::index::type, unsigned int) const |
| virtual bool | submit (dx::stream::encoder::index::type, unsigned int, uint8_t) |
| | submit encoder stage to device return true if successfully submitted; if false is returned the encode state machine will not update the stage value (i.e. if the stage can't be submitted during streaming pause), given the chance to submit the stage at start().
|
| | ~stream () override |
template<typename device_t, typename circular_t = circular, typename super_stream_t = control<object<device_t>>, typename _event_t = event<user>>
class dx::stream::stream< device_t, circular_t, super_stream_t, _event_t >
one stream of the device's desc while it is in use: the ring its clients share, the format they agreed on, and the session its dx::stream::control counts. The ring is allocated once (alloc()/free(), never across a start/stop cycle) and reset by its host alone at a session start - a participant mapping another's ring replaces the run hook and anchors a cursor instead. Bus streams derive from this one: a pipe, a shared memory ring, the kernel's mapping.
template<typename device_t, typename circular_t = circular, typename super_stream_t = control<object<device_t>>, typename _event_t = event<user>>
| dx::stream::stream< device_t, circular_t, super_stream_t, _event_t >::stream |
( |
device_t & | device, |
|
|
const decltype(id)& | id, |
|
|
const desc & | desc ) |
|
inline |
creates circular streaming backing store and frame buffers
< the device's group_t is a bus's own ticking group, not the plain generic container (whose tick() is a stub): only then does a clock-domain stream cascade its share into it
the ring reset and the group share, composed with whatever a more-specific super_stream_t (e.g. usb::pipe) already wired - a no-op for the generic default
template<typename device_t, typename circular_t = circular, typename super_stream_t = control<object<device_t>>, typename _event_t = event<user>>
| virtual void dx::stream::stream< device_t, circular_t, super_stream_t, _event_t >::free |
( |
| ) |
|
|
inlineprotectedvirtualnoexcept |
template<typename device_t, typename circular_t = circular, typename super_stream_t = control<object<device_t>>, typename _event_t = event<user>>
| virtual void dx::stream::stream< device_t, circular_t, super_stream_t, _event_t >::initialize |
( |
| ) |
|
|
inlinevirtual |
< a shared ring takes the wider of its two directions
< this stream's own contribution: the frames its transport keeps ahead of/behind the ring
< a hosted device's ring is its host's (kernel, service, plugin) and attached as it stands - sizing it here would write the ring into a mapping of the host's making
< a fresh ring, zeroed by alloc(), takes its size here
Reimplemented in dx::usb::stream::pipe< device_t, circular_t, stream_t >.
template<typename device_t, typename circular_t = circular, typename super_stream_t = control<object<device_t>>, typename _event_t = event<user>>
submit encoder stage to device return true if successfully submitted; if false is returned the encode state machine will not update the stage value (i.e. if the stage can't be submitted during streaming pause), given the chance to submit the stage at start().
template<typename device_t, typename circular_t = circular, typename super_stream_t = control<object<device_t>>, typename _event_t = event<user>>
the tick's own view of this stream's session: set by the run hook once the ring stands, cleared by the halt hook before the session ends - a plain flag, the tick must never block on a promoted's transition