dxd - dynax driver framework 3.0.2
cross platform open source driver development framework
Loading...
Searching...
No Matches
dx::coreaudio::server::pin< stream_pin_t > Class Template Reference

a pin as the HAL sees it: the stream object, its format list and every control of this pin, each answering the HAL's property calls from the desc and the device's promoted settings More...

#include <dx_coreaudio_server_pin.h>

Inheritance diagram for dx::coreaudio::server::pin< stream_pin_t >:
Collaboration diagram for dx::coreaudio::server::pin< stream_pin_t >:

Classes

struct  [struct].cache

Public Member Functions

virtual void io(::UInt32 operation, ::UInt32 frames, const ::AudioServerPlugInIOCycleInfo* info, void* main)
 operator ::AudioStreamBasicDescription() const
 pin(uint8_t id, typename super::device_t& device, const typename super::device_t::desc::stream::desc& stream_desc, const typename super::desc& pin_desc)
virtual uint32_t property(target target, const ::AudioObjectPropertyAddress& address, void* property, ::UInt32& size, bool set= false)
 generic pin property handler

Public Attributes

struct  cache
const dx::circular::conversion conversion
 the HAL's interleaved buffer in the pin's format against the ring in the stream's
uint8_t id
bool transport{}

Protected Attributes

const dx::stream::clock::bitmap& bitmap
super::circular_t* circular= *this
dx::stream::clock::monitor* monitor= nullptr

Detailed Description

template<typename stream_pin_t>
class dx::coreaudio::server::pin< stream_pin_t >

a pin as the HAL sees it: the stream object, its format list and every control of this pin, each answering the HAL's property calls from the desc and the device's promoted settings

Constructor & Destructor Documentation

◆ pin()

template<typename stream_pin_t>
dx::coreaudio::server::pin<stream_pin_t>::pin(uint8_t id, typename super::device_t& device, const typename super::device_t::desc::stream::desc& stream_desc, const typename super::desc& pin_desc)
inline
Here is the call graph for this function:

Member Function Documentation

◆ io()

template<typename stream_pin_t>
virtual void dx::coreaudio::server::pin<stream_pin_t>::io(::UInt32 operation, ::UInt32 frames, const ::AudioServerPlugInIOCycleInfo* info, void* main)
inlinevirtual
Todo
RT-unsafe: this branch logs (std::clog: heap alloc + os_log) on the coreaudiod IO thread
Todo
whenever a dropout/discontinuity occurs at the default log level. Needs a lock-free
Todo
counter/flag incremented here and drained + logged by a non-RT thread instead, so the
Todo
diagnostic survives at production log levels without doing unsafe work on this thread.
Todo
RT-unsafe: same as the ReadInput branch above (std::clog on the IO thread on dropout).
Here is the call graph for this function:

◆ operator ::AudioStreamBasicDescription()

template<typename stream_pin_t>
dx::coreaudio::server::pin<stream_pin_t>::operator ::AudioStreamBasicDescription() const
inline
Here is the call graph for this function:
Here is the caller graph for this function:

◆ property()

template<typename stream_pin_t>
virtual uint32_t dx::coreaudio::server::pin<stream_pin_t>::property(target target, const ::AudioObjectPropertyAddress& address, void* property, ::UInt32& size, bool set= false)
inlinevirtual

generic pin property handler

  • has property (property= null)
  • get property
  • get property size (property= null)
  • set property (set= true)
  • is property settable (property= null, set= true)
Todo
support sample rate range
Todo
evaluate kAudioStreamPropertyIsActive: seems to never get requested
Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ bitmap

template<typename stream_pin_t>
const dx::stream::clock::bitmap& dx::coreaudio::server::pin<stream_pin_t>::bitmap
protected

◆ cache

◆ circular

template<typename stream_pin_t>
super::circular_t* dx::coreaudio::server::pin<stream_pin_t>::circular= *this
protected

◆ conversion

template<typename stream_pin_t>
const dx::circular::conversion dx::coreaudio::server::pin<stream_pin_t>::conversion
Initial value:
{[this]{
const auto conversion{dx::stream::conversion(this->format, static_cast<const dx::stream::format&>(this->stream.format))};
dx_pass(conversion? ok: not_implemented, "no conversion between the pin's and the stream's format");
return conversion;
}()}
const dx::circular::conversion conversion
the HAL's interleaved buffer in the pin's format against the ring in the stream's
Definition dx_coreaudio_server_pin.h:76
#define dx_pass(test,...)
Definition dx_exception.h:55
Definition dx_coreaudio_stream_device.h:33
circular::conversion conversion(format ext, format ring)
a participant's ring access: its own format against the ring's, resolved once at its start - false wh...
Definition dx_stream.h:206
std::string format(const char *format, arg_t... args)
a printf format into a string - the format dx_pass, dx_assert and the kernel's log take; it leaves no...
Definition dx_exception.h:177
@ ok
Definition macOS/dx_platform.h:205
@ not_implemented
Definition macOS/dx_platform.h:207
what one sample frame looks like, container and content apart: the resolution inside the container's ...
Definition dx_stream.h:89

the HAL's interleaved buffer in the pin's format against the ring in the stream's

◆ id

template<typename stream_pin_t>
uint8_t dx::coreaudio::server::pin<stream_pin_t>::id

◆ monitor

template<typename stream_pin_t>
dx::stream::clock::monitor* dx::coreaudio::server::pin<stream_pin_t>::monitor= nullptr
protected

◆ transport

template<typename stream_pin_t>
bool dx::coreaudio::server::pin<stream_pin_t>::transport{}

the pin holds its ring's transport: it moves its side's index, every other pin is a client at its own position


The documentation for this class was generated from the following file: