Create
Allocates and initializes an instance of the audio device class.
Declaration
static OSSharedPtr<IOUserAudioDevice> Create(IOUserAudioDriver *in_driver, bool in_supports_prewarming, OSString *in_device_uid, OSString *in_model_uid, OSString *in_manufacturer_uid, uint32_t in_zero_timestamp_period);Parameters
- in_driver:
The Iouseraudiodriver that owns this object.
- in_supports_prewarming:
A Boolean value that specifies if the device supports prewarming I/O.
- in_device_uid:
A pointer to an Osstring containing the device UID.
- in_model_uid:
A pointer to an Osstring containing the module UID.
- in_manufacturer_uid:
A pointer to an Osstring containing the manufacturer UID.
- in_zero_timestamp_period:
A Uint32_t whose value indicates the number of sample frames the host can expect between successive timestamps returned from
GetZeroTimeStamp(). In other words, ifGetZeroTimeStamp()returns a sample time ofx, the host can expect that the next valid timestamp it receives will bex + in_zero_timestamp_period.
Return Value
A poiner to an IOUserAudioDevice, if allocation and initialization succeeded.
Discussion
If you subclass IOUserAudioDevice to override this class’ behavior, don’t use Create to allocate and initialize the custom subclass.