class UsbAudioStreamInterface
Defined at line 27 of file ../../src/media/audio/drivers/usb-audio/usb-audio-stream-interface.h
Public Methods
std::unique_ptr<UsbAudioStreamInterface> Create (UsbAudioDevice * parent, DescriptorListMemory::Iterator * iter)
Note that UsbAudioStreamInterfaces are entirely owned by UsbAudioDevice
instances. The stream interface needs to hold a pointer to its parent,
so it is critically important that the owning parent is certain that
the stream interface (and all of its children) have been properly shut
down before exiting. At all times, the lifetime of the stream interface
needs to be a subset of the lifetime of the device parent.
Note, the iterator passed to the create method *must* be pointing at a
valid interface header with class == audio and subclass == streaming
interface. The interface ID encountered in this first header will become
the interface ID of this StreamInterface object.
Defined at line 27 of file ../../src/media/audio/drivers/usb-audio/usb-audio-stream-interface.cc
zx_status_t AddInterface (DescriptorListMemory::Iterator * iter)
Called to add a new alternate streaming interface to this StreamInterface
object. The iterator must be pointing at a valid audio stream interface
descriptor which shares a an IID with this object.
Defined at line 55 of file ../../src/media/audio/drivers/usb-audio/usb-audio-stream-interface.cc
uint8_t iid ()
Defined at line 92 of file ../../src/media/audio/drivers/usb-audio/usb-audio-stream-interface.h
uint16_t max_req_size ()
Defined at line 93 of file ../../src/media/audio/drivers/usb-audio/usb-audio-stream-interface.h
const std::unique_ptr<AudioPath> & path ()
Defined at line 94 of file ../../src/media/audio/drivers/usb-audio/usb-audio-stream-interface.h
const fbl::Vector<FormatMapEntry> & formats ()
Defined at line 95 of file ../../src/media/audio/drivers/usb-audio/usb-audio-stream-interface.h
uint8_t term_link ()
Properties shared by all formats of this stream interface.
Defined at line 98 of file ../../src/media/audio/drivers/usb-audio/usb-audio-stream-interface.h
uint8_t ep_addr ()
Defined at line 99 of file ../../src/media/audio/drivers/usb-audio/usb-audio-stream-interface.h
uint8_t ep_attr ()
Defined at line 100 of file ../../src/media/audio/drivers/usb-audio/usb-audio-stream-interface.h
Direction direction ()
Defined at line 102 of file ../../src/media/audio/drivers/usb-audio/usb-audio-stream-interface.h
EndpointSyncType ep_sync_type ()
Defined at line 106 of file ../../src/media/audio/drivers/usb-audio/usb-audio-stream-interface.h
zx_status_t BuildFormatMap ()
Called after all of the interface descriptors have been discovered and
added to this stream interface to allow the stream interface a chance to
build its list of format ranges and the alternate interface ID which
support them.
Defined at line 164 of file ../../src/media/audio/drivers/usb-audio/usb-audio-stream-interface.cc
zx_status_t LookupFormat (uint32_t frames_per_second, uint16_t channels, audio_sample_format_t sample_format, size_t * out_format_ndx)
Called from the UsbAudioStream to lookup the index of a format which
matches the user's request. Note, this does not actually cause the
interface to switch to this format. Use ActivateFormat, passing the
index retrieved from there, to achieve that.
Defined at line 339 of file ../../src/media/audio/drivers/usb-audio/usb-audio-stream-interface.cc
zx_status_t ActivateFormat (size_t ndx, uint32_t frames_per_second)
Called from the UsbAudioStream to activate the chosen format interface
and to configure the specific frame rate for that interface.
Defined at line 361 of file ../../src/media/audio/drivers/usb-audio/usb-audio-stream-interface.cc
zx_status_t ActivateIdleFormat ()
Called from the UsbAudioStream to activate the alternate idle interface
(if any). Will return ZX_ERR_NOT_SUPPORTED if there is no idle
interface.
Defined at line 418 of file ../../src/media/audio/drivers/usb-audio/usb-audio-stream-interface.cc
void LinkPath (std::unique_ptr<AudioPath> path)
Called at the end of device probing to link a discovered audio path to
this stream interface.
Defined at line 427 of file ../../src/media/audio/drivers/usb-audio/usb-audio-stream-interface.cc
const char * log_prefix ()
Accessor for debug logging.
Defined at line 25 of file ../../src/media/audio/drivers/usb-audio/usb-audio-stream-interface.cc
Records
Friends
class default_delete