Namespaces

Enumerations

enum GainRampType
Name Value
kLinearScale 0

Defined at line 21 of file ../../src/media/audio/services/mixer/mix/gain_control.h

enum GainType
Name Value
kSilent 0
kNonUnity 1
kUnity 2
kRamping 3

Gain type to differentiate between different optimization methods while processing.

Defined at line 22 of file ../../src/media/audio/lib/processing/gain.h

Records

Functions

  • std::shared_ptr<PipelineMixThread> CreatePipelineMixThreadWithoutLoop (Args args)

    Creates a PipelineMixThread that does not include a kernel thread. Useful in tests that want to

    perform mix jobs explicitly.

    Defined at line 9 of file ../../src/media/audio/services/mixer/mix/testing/pipeline_mix_thread_without_loop.cc

  • std::shared_ptr<GraphMixThread> CreateGraphMixThreadWithoutLoop (PipelineMixThread::Args args)

    Creates a GraphMixThread that does not include a kernel thread. Useful in tests that want to

    perform mix jobs explicitly.

    Defined at line 9 of file ../../src/media/audio/services/mixer/fidl/testing/graph_mix_thread_without_loop.cc

  • uint32_t frame_size (const fuchsia_audio::Format & format)

    Convenience function to avoid taking a dependency upon audio/lib/[format | format2].

    Defined at line 15 of file ../../src/media/audio/services/device_registry/common_unittest.h

  • template <typename ProtocolT, template <typename T> class SyncClientT>
    std::pair<SyncClientT<ProtocolT>, fidl::ServerEnd<ProtocolT>> CreateSyncClientOrDie ()

    Creates endpoints for `ProtocolT` or crashes on failure.

    Defined at line 18 of file ../../src/media/audio/services/common/testing/test_server_and_sync_client.h

  • bool DaiFormatIsSupported (ElementId element_id, const std::vector<fuchsia_audio_device::ElementDaiFormatSet> & element_dai_format_sets, const fuchsia_hardware_audio::DaiFormat & format)

    Defined at line 22 of file ../../src/media/audio/services/device_registry/common.cc

  • template <typename ProtocolT, template <typename T> class ClientT>
    std::pair<fidl::ClientEnd<ProtocolT>, fidl::ServerEnd<ProtocolT>> CreateAsyncClientOrDie ()

    Creates endpoints for `ProtocolT` or crashes on failure.

    Defined at line 24 of file ../../src/media/audio/services/common/testing/test_server_and_async_client.h

  • std::unordered_map<ElementId, ElementRecord> MapElements (const std::vector<fuchsia_hardware_audio_signalprocessing::Element> & elements)

    This maps ElementId->ElementRecord but populates only the Element portion of the ElementRecord.

    Defined at line 39 of file ../../src/media/audio/services/device_registry/signal_processing_utils.cc

  • void LogClockAdjustment (const Clock & clock, std::optional<int32_t> last_rate_ppm, int32_t next_rate_ppm, zx::duration pos_error, const ::media::audio::clock::PidControl & pid)

    Log an adjustment to a clock. This is typically called just before `clock.SetRate`.

    Defined at line 29 of file ../../src/media/audio/lib/clock/logging.cc

  • std::unordered_set<ElementId> dais (const std::unordered_map<ElementId, ElementRecord> & element_map)

    Defined at line 16 of file ../../src/media/audio/services/device_registry/signal_processing_utils.cc

  • std::unordered_set<ElementId> ring_buffers (const std::unordered_map<ElementId, ElementRecord> & element_map)

    Defined at line 27 of file ../../src/media/audio/services/device_registry/signal_processing_utils.cc

  • template <GainType Type>
    float ApplyGain (float value, float scale)

    Applies gain `scale` to `value` with `Type` specific optimizations.

    Defined at line 31 of file ../../src/media/audio/lib/processing/gain.h

  • void LogFidlClientError (fidl::UnbindInfo error, const std::string & tag)

    Defined at line 35 of file ../../src/media/audio/services/device_registry/adr_server_unittest_base.h

  • float DbToScale (float db)

    Converts gain `db` to scale.

    Defined at line 42 of file ../../src/media/audio/lib/processing/gain.h

  • float ScaleToDb (float scale)

    Converts gain `scale` to decibels.

    Defined at line 48 of file ../../src/media/audio/lib/processing/gain.h

  • bool RingBufferFormatIsSupported (ElementId element_id, const std::vector<fuchsia_audio_device::ElementRingBufferFormatSet> & element_ring_buffer_format_sets, const fuchsia_hardware_audio::Format2 & format)

    Defined at line 114 of file ../../src/media/audio/services/device_registry/common.cc

  • MixJobContext & DefaultCtx ()

    Can be used when any MixJobContext will do.

    Defined at line 40 of file ../../src/media/audio/services/mixer/mix/testing/defaults.cc

  • std::unordered_map<TopologyId, std::vector<fuchsia_hardware_audio_signalprocessing::EdgePair>> MapTopologies (const std::vector<fuchsia_hardware_audio_signalprocessing::Topology> & topologies)

    Returns empty map if any topology_id values are duplicated.

    Defined at line 58 of file ../../src/media/audio/services/device_registry/signal_processing_utils.cc

  • Fixed TimelineFunctionOffsetInFracFrames (const TimelineFunction & a, const TimelineFunction & b)

    Returns the offset `b - a`. Both functions must have the same slope. Each function is:

    ```

    f(x) = (x-x0) * slope + y0

    ```

    We assume these functions convert from time to fractional frames, meaning `x` is an int64_t time

    while `y` is a Fixed frame number. Hence the offset is a Fixed.

    REQUIRED: a.rate() == b.rate()

    Defined at line 11 of file ../../src/media/audio/services/mixer/mix/timeline_function_math.cc

  • const ClockSnapshots & DefaultClockSnapshots ()

    A set of clock snapshots that can be used when any will do.

    Defined at line 42 of file ../../src/media/audio/services/mixer/mix/testing/defaults.cc

  • bool ElementHasOutgoingEdges (const std::vector<fuchsia_hardware_audio_signalprocessing::EdgePair> & topology, ElementId element_id)

    Defined at line 76 of file ../../src/media/audio/services/device_registry/signal_processing_utils.cc

  • std::shared_ptr<Clock> DefaultClock ()

    A reference clock to use when any clock will do.

    This clock is guaranteed to exist in `MixJobContext.clocks()` and `DefaultClockSnapshots()`.

    Defined at line 44 of file ../../src/media/audio/services/mixer/mix/testing/defaults.cc

  • bool ElementHasIncomingEdges (const std::vector<fuchsia_hardware_audio_signalprocessing::EdgePair> & topology, ElementId element_id)

    Defined at line 85 of file ../../src/media/audio/services/device_registry/signal_processing_utils.cc

  • bool operator== (const UnreadableClock & lhs, const std::shared_ptr<const Clock> & rhs)

    Reports whether an UnreadableClock holds a given `std::shared_ptr

    <const

    Clock>`.

    Defined at line 39 of file ../../src/media/audio/lib/clock/unreadable_clock.h

  • UnreadableClock DefaultUnreadableClock ()

    Defined at line 46 of file ../../src/media/audio/services/mixer/mix/testing/defaults.cc

  • bool operator!= (const UnreadableClock & lhs, const std::shared_ptr<const Clock> & rhs)

    Defined at line 42 of file ../../src/media/audio/lib/clock/unreadable_clock.h

  • bool operator== (const std::shared_ptr<const Clock> & lhs, const UnreadableClock & rhs)

    Defined at line 45 of file ../../src/media/audio/lib/clock/unreadable_clock.h

  • bool operator!= (const std::shared_ptr<const Clock> & lhs, const UnreadableClock & rhs)

    Defined at line 48 of file ../../src/media/audio/lib/clock/unreadable_clock.h

  • std::shared_ptr<ClockSynchronizer> DefaultClockSync ()

    A noop clock synchronizer to use when any will do.

    Defined at line 48 of file ../../src/media/audio/services/mixer/mix/testing/defaults.cc

  • void RecomputeMaxDownstreamDelays (Node & node, std::map<ThreadId, std::vector<fit::closure>> & closures)

    Recomputes delays at `node`. These are recomputed incrementally:

    * For downstream delays, we assume the delays are already correct for all of `node`'s outgoing

    edges. If a downstream delay has changed at `node`, we recurse on `node`'s incoming edges.

    * For upstream delays, we assume the delays are already correct for all of `node`'s incoming

    edges. If an upstream delay has changed at `node`, we recurse on `node`'s outgoing edges.

    If any delays change, the `closures` mapping is updated with a set of (ThreadId, closure) pairs,

    where `closure` should be run on `ThreadId`. These closures copy the delay changes into state on

    mix threads, such as state in ConsumerStage. This is a `map` instead of an `unordered_map` so the

    caller can process the ThreadIds in a deterministic order (which is helpful in tests).

    REQUIRED: the property to compute is defined at `node`

    Defined at line 113 of file ../../src/media/audio/services/mixer/fidl/reachability.cc

  • bool ClientIsValidForDeviceType (const fuchsia_audio_device::DeviceType & device_type, const fuchsia_audio_device::DriverClient & driver_client)

    Utility functions to validate direct responses from audio drivers.

    Defined at line 58 of file ../../src/media/audio/services/device_registry/validate.cc

  • TimelineFunction DefaultPresentationTimeToFracFrame (const Format & format)

    A TimelineFunction that defines t=0 to be the presentation time for frame 0.

    Defined at line 53 of file ../../src/media/audio/services/mixer/mix/testing/defaults.cc

  • void RecomputeMaxUpstreamDelays (Node & node, std::map<ThreadId, std::vector<fit::closure>> & closures)

    Defined at line 179 of file ../../src/media/audio/services/mixer/fidl/reachability.cc

  • std::vector<fuchsia_audio_device::PcmFormatSet> TranslateRingBufferFormatSets (const std::vector<fuchsia_hardware_audio::SupportedFormats2> & ring_buffer_format_sets)

    Translate from fuchsia_hardware_audio::SupportedFormats to fuchsia_audio_device::PcmFormatSet.

    Defined at line 71 of file ../../src/media/audio/services/device_registry/validate.cc

  • std::map<ThreadId, std::vector<fit::closure>> RecomputeDelays (Node & source, Node & dest)

    Call the above functions assuming that the edge `source -> dest` was just created or deleted.

    Defined at line 224 of file ../../src/media/audio/services/mixer/fidl/reachability.cc

  • std::shared_ptr<SimplePacketQueueProducerStage> MakeDefaultPacketQueue (const Format & format, std::string_view name)

    Constructs a SimplePacketQueueProducerStage with the given `format`, DefaultClock(), and optional

    `name`. The returned queue can be mutated via its `push` and `clear` methods.

    Defined at line 57 of file ../../src/media/audio/services/mixer/mix/testing/defaults.cc

  • fuchsia_hardware_audio::DaiFormat SafeDaiFormatFromElementDaiFormatSets (ElementId element_id, const std::vector<fuchsia_audio_device::ElementDaiFormatSet> & element_dai_format_sets)

    ////////////////////////////

    Codec-related functions

    From a multi-element collection, each with many DaiSupportedFormats, get a DaiFormat.

    Defined at line 26 of file ../../src/media/audio/services/device_registry/common_unittest.cc

  • fuchsia_hardware_audio::DaiFormat SafeDaiFormatFromDaiFormatSets (const std::vector<fuchsia_hardware_audio::DaiSupportedFormats> & dai_format_sets)

    From many DaiSupportedFormats, get a DaiFormat.

    Defined at line 71 of file ../../src/media/audio/services/device_registry/common_unittest.cc

  • fuchsia_hardware_audio::DaiFormat SecondDaiFormatFromElementDaiFormatSets (ElementId element_id, const std::vector<fuchsia_audio_device::ElementDaiFormatSet> & element_dai_format_sets)

    From a multi-element collection, each with many DaiSupportedFormats, get a DIFFERENT DaiFormat.

    Defined at line 41 of file ../../src/media/audio/services/device_registry/common_unittest.cc

  • template <typename ProtocolT>
    std::pair<fidl::SyncClient<ProtocolT>, fidl::ServerEnd<ProtocolT>> CreateNaturalSyncClientOrDie ()

    Defined at line 74 of file ../../src/media/audio/services/common/testing/test_server_and_sync_client.h

  • template <typename ProtocolT>
    std::pair<fidl::WireSyncClient<ProtocolT>, fidl::ServerEnd<ProtocolT>> CreateWireSyncClientOrDie ()

    Defined at line 83 of file ../../src/media/audio/services/common/testing/test_server_and_sync_client.h

  • template <typename ProtocolT>
    std::pair<fidl::ClientEnd<ProtocolT>, fidl::ServerEnd<ProtocolT>> CreateNaturalAsyncClientOrDie ()

    Defined at line 90 of file ../../src/media/audio/services/common/testing/test_server_and_async_client.h

  • fuchsia_hardware_audio::DaiFormat SecondDaiFormatFromDaiFormatSets (const std::vector<fuchsia_hardware_audio::DaiSupportedFormats> & dai_format_sets)

    From many DaiSupportedFormats, get a DIFFERENT DaiFormat.

    Defined at line 92 of file ../../src/media/audio/services/device_registry/common_unittest.cc

  • fuchsia_hardware_audio::DaiFormat UnsupportedDaiFormatFromElementDaiFormatSets (ElementId element_id, const std::vector<fuchsia_audio_device::ElementDaiFormatSet> & element_dai_format_sets)

    From a multi-element collection, each with many DaiSupportedFormats,

    get a DaiFormat that is UNSUPPORTED (but still a valid format).

    Defined at line 56 of file ../../src/media/audio/services/device_registry/common_unittest.cc

  • template <typename ProtocolT>
    std::pair<fidl::ClientEnd<ProtocolT>, fidl::ServerEnd<ProtocolT>> CreateWireAsyncClientOrDie ()

    Defined at line 99 of file ../../src/media/audio/services/common/testing/test_server_and_async_client.h

  • std::ostream & operator<< (std::ostream & out, ClockSynchronizer::Mode mode)

    Defined at line 114 of file ../../src/media/audio/lib/clock/clock_synchronizer.h

  • fuchsia_hardware_audio::DaiFormat UnsupportedDaiFormatFromDaiFormatSets (const std::vector<fuchsia_hardware_audio::DaiSupportedFormats> & dai_format_sets)

    From many DaiSupportedFormats, get a DaiFormat that is UNSUPPORTED (but still valid).

    Defined at line 135 of file ../../src/media/audio/services/device_registry/common_unittest.cc

  • bool ValidateRingBufferFormatSets (const std::vector<fuchsia_hardware_audio::SupportedFormats2> & ring_buffer_format_sets)

    Defined at line 157 of file ../../src/media/audio/services/device_registry/validate.cc

  • std::ostream & operator<< (std::ostream & out, const fuchsia_hardware_audio::SampleFormat & rb_sample_format)

    fuchsia_hardware_audio types

    Defined at line 158 of file ../../src/media/audio/services/device_registry/logging.h

  • std::ostream & operator<< (std::ostream & out, const fuchsia_hardware_audio::PcmFormat & pcm_format)

    Defined at line 169 of file ../../src/media/audio/services/device_registry/logging.h

  • std::ostream & operator<< (std::ostream & out, const fuchsia_hardware_audio::PlugDetectCapabilities & plug_caps)

    Defined at line 177 of file ../../src/media/audio/services/device_registry/logging.h

  • fuchsia_audio::Format SafeRingBufferFormatFromElementRingBufferFormatSets (ElementId element_id, const std::vector<fuchsia_audio_device::ElementRingBufferFormatSet> & element_ring_buffer_format_sets)

    From a multi-element collection, each with many fad::PcmFormatSet, get a fa::Format.

    Defined at line 186 of file ../../src/media/audio/services/device_registry/common_unittest.cc

  • fuchsia_audio::Format SafeRingBufferFormatFromRingBufferFormatSets (const std::vector<fuchsia_audio_device::PcmFormatSet> & ring_buffer_format_sets)

    ////////////////////////////

    RingBuffer-related functions

    From many fad::PcmFormatSet, get a fuchsia_audio::Format.

    Defined at line 158 of file ../../src/media/audio/services/device_registry/common_unittest.cc

  • std::ostream & operator<< (std::ostream & out, const fuchsia_hardware_audio::DaiSampleFormat & dai_sample_format)

    Defined at line 186 of file ../../src/media/audio/services/device_registry/logging.h

  • std::ostream & operator<< (std::ostream & out, const fuchsia_hardware_audio::DaiFrameFormat & dai_frame_format)

    Defined at line 201 of file ../../src/media/audio/services/device_registry/logging.h

  • fuchsia_audio::Format SecondRingBufferFormatFromElementRingBufferFormatSets (ElementId element_id, const std::vector<fad::ElementRingBufferFormatSet> & element_ring_buffer_format_sets)

    From a multi-element collection, each with many fad::PcmFormatSet, get a DIFFERENT fa::Format.

    Defined at line 202 of file ../../src/media/audio/services/device_registry/common_unittest.cc

  • fuchsia_hardware_audio::Format2 SafeDriverRingBufferFormatFromDriverRingBufferFormatSets (const std::vector<fuchsia_hardware_audio::SupportedFormats2> & driver_ring_buffer_format_sets)

    From many SupportedFormats, get a Format.

    Defined at line 218 of file ../../src/media/audio/services/device_registry/common_unittest.cc

  • bool ExistsPath (const Node & source, const Node & dest)

    Reports whether there exists a path from `source` to `dest`. The nodes may be ordinary nodes

    and/or meta nodes. For any given meta node M, there are implicit paths from M's child source

    nodes, to M itself, to M's child destination nodes. That is, given:

    ```

    A

    |

    +----------V-----------+

    | +---+ M |

    | | I | | // M.child_sources()

    | +---+ |

    | +----+ +----+ +----+ |

    | | O1 | | O2 | | O3 | | // M.child_dests()

    | +----+ +----+ +----+ |

    +---|------|------|----+

    | | |

    V V V

    B C D

    ```

    There exists paths:

    ```

    A -> I -> M -> O1 -> B

    A -> I -> M -> O2 -> C

    A -> I -> M -> O3 -> D

    ```

    Defined at line 231 of file ../../src/media/audio/services/mixer/fidl/reachability.cc

  • std::ostream & operator<< (std::ostream & out, const PacketView & packet)

    Convenience for logging.

    Defined at line 67 of file ../../src/media/audio/services/mixer/mix/packet_view.cc

  • CacheT * CreateSincFilterCoefficientTableCache ()

    Defined at line 128 of file ../../src/media/audio/lib/processing/filter.cc

  • fuchsia_audio::Format SecondRingBufferFormatFromRingBufferFormatSets (const std::vector<fad::PcmFormatSet> & ring_buffer_format_sets)

    From many fad::PcmFormatSet, get a DIFFERENT fuchsia_audio::Format.

    Defined at line 168 of file ../../src/media/audio/services/device_registry/common_unittest.cc

  • fha::Format2 SecondDriverRingBufferFormatFromDriverRingBufferFormatSets (const std::vector<fha::SupportedFormats2> & driver_ring_buffer_format_sets)

    From many SupportedFormats, get a DIFFERENT Format.

    Defined at line 238 of file ../../src/media/audio/services/device_registry/common_unittest.cc

  • std::ostream & operator<< (std::ostream & out, const std::optional<fuchsia_hardware_audio_signalprocessing::ElementType> & element_type)

    Defined at line 246 of file ../../src/media/audio/services/device_registry/logging.h

  • std::ostream & operator<< (std::ostream & out, const std::optional<fuchsia_hardware_audio_signalprocessing::ThresholdType> & threshold_type)

    Defined at line 282 of file ../../src/media/audio/services/device_registry/logging.h

  • fha::Format2 SecondDriverRingBufferFormatFromElementDriverRingBufferFormatSets (ElementId element_id, const std::vector<std::pair<ElementId, std::vector<fha::SupportedFormats2>>> & element_driver_ring_buffer_format_sets)

    From a multi-element collection, each with many SupportedFormats, get ANOTHER Format.

    Defined at line 287 of file ../../src/media/audio/services/device_registry/common_unittest.cc

  • std::ostream & operator<< (std::ostream & out, const std::optional<fuchsia_hardware_audio_signalprocessing::LevelType> & level_type)

    Defined at line 298 of file ../../src/media/audio/services/device_registry/logging.h

  • template <GainType Type, bool Accumulate>
    void MixSample (float source_sample, float * dest_sample_ptr, float scale)

    Mixes `source_sample` to `dest_sample_ptr` with a gain `scale` of `Type`.

    Defined at line 303 of file ../../src/media/audio/lib/processing/sampler.h

  • std::ostream & operator<< (std::ostream & out, const std::optional<fuchsia_hardware_audio_signalprocessing::EqualizerBandType> & eq_band_type)

    Defined at line 314 of file ../../src/media/audio/services/device_registry/logging.h

  • bool ValidateCodecProperties (const fuchsia_hardware_audio::CodecProperties & codec_props, std::optional<const fuchsia_hardware_audio::PlugState> plug_state)

    Defined at line 328 of file ../../src/media/audio/services/device_registry/validate.cc

  • std::ostream & operator<< (std::ostream & out, const std::optional<fuchsia_hardware_audio_signalprocessing::GainType> & gain_type)

    Defined at line 338 of file ../../src/media/audio/services/device_registry/logging.h

  • std::ostream & operator<< (std::ostream & out, const std::optional<fuchsia_hardware_audio_signalprocessing::GainDomain> & gain_domain)

    Defined at line 354 of file ../../src/media/audio/services/device_registry/logging.h

  • std::ostream & operator<< (std::ostream & out, const std::optional<fuchsia_hardware_audio_signalprocessing::DaiInterconnect> & dai_interconnect)

    Defined at line 372 of file ../../src/media/audio/services/device_registry/logging.h

  • std::ostream & operator<< (std::ostream & out, const fuchsia_audio::SampleType & sample_type)

    Defined at line 393 of file ../../src/media/audio/services/device_registry/logging.h

  • std::ostream & operator<< (std::ostream & out, const std::optional<fuchsia_audio_device::DeviceType> & device_type)

    fuchsia_audio_device types

    Defined at line 411 of file ../../src/media/audio/services/device_registry/logging.h

  • std::ostream & operator<< (std::ostream & out, const fuchsia_audio_device::ControlSetDaiFormatError & error)

    Defined at line 425 of file ../../src/media/audio/services/device_registry/logging.h

  • std::ostream & operator<< (std::ostream & out, const std::optional<fuchsia_audio_device::PlugDetectCapabilities> & plug_caps)

    Defined at line 446 of file ../../src/media/audio/services/device_registry/logging.h

  • std::ostream & operator<< (std::ostream & out, const fuchsia_audio_device::PlugState & plug_state)

    Defined at line 461 of file ../../src/media/audio/services/device_registry/logging.h

  • std::string to_string (std::optional<bool> selector, const std::string & true_str, const std::string & false_str, const std::string & null_str)

    Defined at line 473 of file ../../src/media/audio/services/device_registry/logging.h

  • std::string to_string (const std::optional<std::string> & str, const std::string & null_str)

    Defined at line 481 of file ../../src/media/audio/services/device_registry/logging.h

  • std::string to_string (const std::optional<uint64_t> & val, const std::string & null_str)

    Defined at line 488 of file ../../src/media/audio/services/device_registry/logging.h

  • bool ValidatePlugState (const fuchsia_hardware_audio::PlugState & plug_state, std::optional<fuchsia_hardware_audio::PlugDetectCapabilities> plug_detect_capabilities)

    Defined at line 550 of file ../../src/media/audio/services/device_registry/validate.cc

  • bool ValidateCodecFormatInfo (const fuchsia_hardware_audio::CodecFormatInfo & format_info)

    Defined at line 514 of file ../../src/media/audio/services/device_registry/validate.cc

  • bool ValidateCompositeProperties (const fuchsia_hardware_audio::CompositeProperties & composite_props)

    Defined at line 533 of file ../../src/media/audio/services/device_registry/validate.cc

  • bool ValidateDeviceInfo (const fuchsia_audio_device::Info & device_info)

    Validate only DeviceInfo-specific aspects. For example, don't re-validate format correctness.

    Defined at line 579 of file ../../src/media/audio/services/device_registry/validate.cc

  • bool ValidateTopologies (const std::vector<fuchsia_hardware_audio_signalprocessing::Topology> & topologies, const std::unordered_map<ElementId, ElementRecord> & element_map)

    Defined at line 1823 of file ../../src/media/audio/services/device_registry/validate.cc

  • bool ValidateTopology (const fuchsia_hardware_audio_signalprocessing::Topology & topology, const std::unordered_map<ElementId, ElementRecord> & element_map)

    Defined at line 1712 of file ../../src/media/audio/services/device_registry/validate.cc

  • bool ValidateElements (const std::vector<fuchsia_hardware_audio_signalprocessing::Element> & elements)

    Defined at line 1692 of file ../../src/media/audio/services/device_registry/validate.cc

  • bool ValidateElement (const fuchsia_hardware_audio_signalprocessing::Element & element)

    Defined at line 1631 of file ../../src/media/audio/services/device_registry/validate.cc

  • bool ValidateDaiInterconnectElement (const fuchsia_hardware_audio_signalprocessing::Element & element)

    Validate the type-specific table for this element type.

    Defined at line 1496 of file ../../src/media/audio/services/device_registry/validate.cc

  • bool ValidateDynamicsElement (const fuchsia_hardware_audio_signalprocessing::Element & element)

    Validate the type-specific table for this element type.

    Defined at line 1510 of file ../../src/media/audio/services/device_registry/validate.cc

  • bool ValidateEqualizerElement (const fuchsia_hardware_audio_signalprocessing::Element & element)

    Validate the type-specific table for this element type.

    Defined at line 1537 of file ../../src/media/audio/services/device_registry/validate.cc

  • bool ValidateGainElement (const fuchsia_hardware_audio_signalprocessing::Element & element)

    Validate the type-specific table for this element type.

    Defined at line 1590 of file ../../src/media/audio/services/device_registry/validate.cc

  • bool ValidateVendorSpecificElement (const fuchsia_hardware_audio_signalprocessing::Element & element)

    Validate the type-specific table for this element type.

    Defined at line 1620 of file ../../src/media/audio/services/device_registry/validate.cc

  • bool ValidateElementState (const fuchsia_hardware_audio_signalprocessing::ElementState & element_state, const fuchsia_hardware_audio_signalprocessing::Element & element)

    Defined at line 1343 of file ../../src/media/audio/services/device_registry/validate.cc

  • fuchsia_hardware_audio::Format2 SafeDriverRingBufferFormatFromElementDriverRingBufferFormatSets (ElementId element_id, const std::vector<std::pair<ElementId, std::vector<fuchsia_hardware_audio::SupportedFormats2>>> & element_driver_ring_buffer_format_sets)

    From a multi-element collection, each with many SupportedFormats, get a Format.

    Defined at line 271 of file ../../src/media/audio/services/device_registry/common_unittest.cc

  • bool ValidateDaiInterconnectElementState (const fuchsia_hardware_audio_signalprocessing::ElementState & element_state, const fuchsia_hardware_audio_signalprocessing::Element & element)

    Validate the type-specific state for this element type.

    Defined at line 797 of file ../../src/media/audio/services/device_registry/validate.cc

  • bool ValidateDynamicsElementState (const fuchsia_hardware_audio_signalprocessing::ElementState & element_state, const fuchsia_hardware_audio_signalprocessing::Element & element)

    Validate the type-specific state for this element type.

    Defined at line 846 of file ../../src/media/audio/services/device_registry/validate.cc

  • bool ValidateEqualizerElementState (const fuchsia_hardware_audio_signalprocessing::ElementState & element_state, const fuchsia_hardware_audio_signalprocessing::Element & element)

    Validate the type-specific state for this element type.

    Defined at line 1025 of file ../../src/media/audio/services/device_registry/validate.cc

  • bool ValidateGainElementState (const fuchsia_hardware_audio_signalprocessing::ElementState & element_state, const fuchsia_hardware_audio_signalprocessing::Element & element)

    Validate the type-specific state for this element type.

    Defined at line 1225 of file ../../src/media/audio/services/device_registry/validate.cc

  • bool ValidateVendorSpecificElementState (const fuchsia_hardware_audio_signalprocessing::ElementState & element_state, const fuchsia_hardware_audio_signalprocessing::Element & element)

    Validate the type-specific state for this element type.

    Defined at line 1294 of file ../../src/media/audio/services/device_registry/validate.cc

  • bool ValidateSettableElementState (const fuchsia_hardware_audio_signalprocessing::SettableElementState & element_state, const fuchsia_hardware_audio_signalprocessing::Element & element)

    Defined at line 1432 of file ../../src/media/audio/services/device_registry/validate.cc

  • bool ValidateSettableDynamicsElementState (const fuchsia_hardware_audio_signalprocessing::SettableElementState & element_state, const fuchsia_hardware_audio_signalprocessing::Element & element)

    Validate the type-specific state for this element type.

    Defined at line 917 of file ../../src/media/audio/services/device_registry/validate.cc

  • bool ValidateSettableEqualizerElementState (const fuchsia_hardware_audio_signalprocessing::SettableElementState & element_state, const fuchsia_hardware_audio_signalprocessing::Element & element)

    Validate the type-specific state for this element type.

    Defined at line 1093 of file ../../src/media/audio/services/device_registry/validate.cc

  • bool ValidateSettableGainElementState (const fuchsia_hardware_audio_signalprocessing::SettableElementState & element_state, const fuchsia_hardware_audio_signalprocessing::Element & element)

    Validate the type-specific state for this element type.

    Defined at line 1259 of file ../../src/media/audio/services/device_registry/validate.cc

  • std::string UidToString (std::optional<UniqueId> unique_instance_id)

    Defined at line 515 of file ../../src/media/audio/services/device_registry/logging.cc

  • void LogPlugState (const fuchsia_hardware_audio::PlugState & plug_state)

    Defined at line 716 of file ../../src/media/audio/services/device_registry/logging.cc

  • bool ValidateSettableVendorSpecificElementState (const fuchsia_hardware_audio_signalprocessing::SettableElementState & element_state, const fuchsia_hardware_audio_signalprocessing::Element & element)

    Validate the type-specific state for this element type.

    Defined at line 1319 of file ../../src/media/audio/services/device_registry/validate.cc

  • void LogCodecProperties (const fuchsia_hardware_audio::CodecProperties & codec_props)

    Defined at line 731 of file ../../src/media/audio/services/device_registry/logging.cc

  • void LogCodecFormatInfo (std::optional<fuchsia_hardware_audio::CodecFormatInfo> format_info)

    Defined at line 861 of file ../../src/media/audio/services/device_registry/logging.cc

  • void LogCompositeProperties (const fuchsia_hardware_audio::CompositeProperties & composite_props)

    Defined at line 885 of file ../../src/media/audio/services/device_registry/logging.cc

  • std::vector<PipelineStagePtr> MoveNodeToThread (Node & node, std::shared_ptr<GraphThread> new_thread, std::shared_ptr<GraphThread> expected_thread)

    Moves `node` and its source tree to `thread`, where `node` is assumed to be currently attached to

    `expected_thread`. A node's "source tree" is the set of upstream nodes n ∈ N such that there

    exists a path from each n to `node`, where the path does not go through a consumer node.

    For example, in the following diagram:

    ```

    A

    |

    V

    +------------+

    | C |

    | splitter |

    | P1 P2 P3 |

    +------------+ H

    | | | |

    V V V V

    D E F G

    | |

    +-----+-----+

    |

    V

    N

    ```

    If C has type `Node::Type::kConsumer`, then `MoveNodetoThread(N, new_thread, old_thread)` will

    move the following nodes to `new_thread`: {N, F, G, P3, H}. [By

    construction](../docs/execution_model.md), this set of nodes must form a tree rooted at N.

    Before a node is moved to `new_thread`, we check that the node is currently attached to

    `expected_thread`. We will crash if this expectation is not satisfied.

    Returns the set of PipelineStages that must move to `new_thread->pipeline_thread()`.

    REQUIRED: node.type() != Node::Type::kMeta

    Defined at line 283 of file ../../src/media/audio/services/mixer/fidl/reachability.cc

  • bool ValidateRingBufferFormat (const fuchsia_hardware_audio::Format2 & ring_buffer_format)

    Defined at line 658 of file ../../src/media/audio/services/device_registry/validate.cc

  • void LogDeviceAddition (const fuchsia_audio_device::Info & device_info)

    Signal the successful detection, querying, initialization and addition of a device.

    Defined at line 998 of file ../../src/media/audio/services/device_registry/logging.cc

  • bool ValidateSampleFormatCompatibility (uint8_t bytes_per_sample, fuchsia_hardware_audio::SampleFormat sample_format)

    Defined at line 716 of file ../../src/media/audio/services/device_registry/validate.cc

  • void LogDeviceRemoval (const std::optional<fuchsia_audio_device::Info> & device_info)

    Mirror (bookend) the analogous `LogDeviceAddition` for device removal. Removals may be "normal"

    (USB unplug) or caused by fatal error. The latter can happen before `device_info` is created.

    Defined at line 1013 of file ../../src/media/audio/services/device_registry/logging.cc

  • void LogDeviceError (const std::optional<fuchsia_audio_device::Info> & device_info)

    Mirror (bookend) the analogous `LogDeviceAddition`, for a device error.

    This can also occur before a device has been successfully added: device_info may not be set.

    Defined at line 1034 of file ../../src/media/audio/services/device_registry/logging.cc

  • void LogDeviceInfo (const fuchsia_audio_device::Info & device_info)

    Defined at line 1053 of file ../../src/media/audio/services/device_registry/logging.cc

  • bool ValidateDaiFormatSets (const std::vector<fuchsia_hardware_audio::DaiSupportedFormats> & dai_format_sets)

    Defined at line 355 of file ../../src/media/audio/services/device_registry/validate.cc

  • void LogElementMap (const std::unordered_map<ElementId, ElementRecord> & element_map)

    Defined at line 957 of file ../../src/media/audio/services/device_registry/logging.cc

  • bool ValidateDaiFormat (const fuchsia_hardware_audio::DaiFormat & dai_format)

    Defined at line 444 of file ../../src/media/audio/services/device_registry/validate.cc

  • void LogElements (const std::vector<fuchsia_hardware_audio_signalprocessing::Element> & elements)

    Defined at line 944 of file ../../src/media/audio/services/device_registry/logging.cc

  • bool ValidateRingBufferProperties (const fuchsia_hardware_audio::RingBufferProperties & rb_props)

    Defined at line 638 of file ../../src/media/audio/services/device_registry/validate.cc

  • void LogTopologies (const std::vector<fuchsia_hardware_audio_signalprocessing::Topology> & topologies)

    Defined at line 984 of file ../../src/media/audio/services/device_registry/logging.cc

  • bool ValidateRingBufferVmo (const zx::vmo & vmo, uint32_t num_frames, const fuchsia_hardware_audio::Format2 & format, zx_rights_t required_rights)

    Defined at line 731 of file ../../src/media/audio/services/device_registry/validate.cc

  • void LogElement (const fuchsia_hardware_audio_signalprocessing::Element & element)

    Defined at line 935 of file ../../src/media/audio/services/device_registry/logging.cc

  • void LogTopology (const fuchsia_hardware_audio_signalprocessing::Topology & topology)

    Defined at line 975 of file ../../src/media/audio/services/device_registry/logging.cc

  • bool ValidateDelayInfo (const fuchsia_hardware_audio::DelayInfo & delay_info)

    Defined at line 773 of file ../../src/media/audio/services/device_registry/validate.cc

  • void LogElementState (const std::optional<fuchsia_hardware_audio_signalprocessing::ElementState> & element_state)

    Defined at line 926 of file ../../src/media/audio/services/device_registry/logging.cc

  • void LogSettableElementState (const std::optional<fuchsia_hardware_audio_signalprocessing::SettableElementState> & element_state)

    Defined at line 917 of file ../../src/media/audio/services/device_registry/logging.cc

  • void LogElementRingBufferFormatSets (const std::vector<fuchsia_audio_device::ElementRingBufferFormatSet> & element_ring_buffer_format_sets)

    Defined at line 537 of file ../../src/media/audio/services/device_registry/logging.cc

  • void LogElementRingBufferFormatSet (const fuchsia_audio_device::ElementRingBufferFormatSet & element_ring_buffer_format_set)

    Defined at line 548 of file ../../src/media/audio/services/device_registry/logging.cc

  • void LogTranslatedRingBufferFormatSets (const std::vector<fuchsia_audio_device::PcmFormatSet> & translated_ring_buffer_format_sets)

    Defined at line 568 of file ../../src/media/audio/services/device_registry/logging.cc

  • void LogTranslatedRingBufferFormatSet (const fuchsia_audio_device::PcmFormatSet & translated_ring_buffer_format_set)

    Defined at line 582 of file ../../src/media/audio/services/device_registry/logging.cc

  • std::ostream & operator<< (std::ostream & out, const Format & format)

    Defined at line 479 of file ../../src/media/audio/lib/format2/format.cc

  • void LogRingBufferFormatSets (const std::vector<fuchsia_hardware_audio::SupportedFormats2> & ring_buffer_format_sets)

    Defined at line 634 of file ../../src/media/audio/services/device_registry/logging.cc

  • void LogRingBufferFormat (const fuchsia_hardware_audio::Format2 & ring_buffer_format)

    Defined at line 1291 of file ../../src/media/audio/services/device_registry/logging.cc

  • void LogElementDaiFormatSets (const std::vector<fuchsia_audio_device::ElementDaiFormatSet> & element_dai_format_sets)

    Defined at line 761 of file ../../src/media/audio/services/device_registry/logging.cc

  • void LogElementDaiFormatSet (const fuchsia_audio_device::ElementDaiFormatSet & element_dai_format_set)

    Defined at line 771 of file ../../src/media/audio/services/device_registry/logging.cc

  • void LogDaiFormatSets (const std::vector<fuchsia_hardware_audio::DaiSupportedFormats> & dai_format_sets)

    Defined at line 789 of file ../../src/media/audio/services/device_registry/logging.cc

  • void LogDaiFormat (std::optional<fuchsia_hardware_audio::DaiFormat> dai_format)

    Defined at line 839 of file ../../src/media/audio/services/device_registry/logging.cc

  • void LogRingBufferProperties (const fuchsia_hardware_audio::RingBufferProperties & rb_props)

    Defined at line 1267 of file ../../src/media/audio/services/device_registry/logging.cc

  • void LogRingBufferVmo (const zx::vmo & vmo, uint32_t num_frames, fuchsia_hardware_audio::Format2 rb_format)

    Defined at line 1315 of file ../../src/media/audio/services/device_registry/logging.cc

  • void LogDelayInfo (const fuchsia_hardware_audio::DelayInfo & info)

    Defined at line 1374 of file ../../src/media/audio/services/device_registry/logging.cc

  • void LogActiveChannels (uint64_t channel_bitmask, zx::time set_time)

    Defined at line 1363 of file ../../src/media/audio/services/device_registry/logging.cc

  • void LogObjectCounts ()

    Enabled by kLogObjectCounts.

    Defined at line 1393 of file ../../src/media/audio/services/device_registry/logging.cc

  • std::ostream & operator<< (std::ostream & out, State device_state)

    Defined at line 537 of file ../../src/media/audio/services/device_registry/device.h

  • std::ostream & operator<< (std::ostream & outRingBufferState ring_buffer_state)

    Defined at line 550 of file ../../src/media/audio/services/device_registry/device.h

Variables

const bool kTraceFilterComputation

Defined at line 12 of file ../../src/media/audio/lib/processing/flags.h

const cpp20::span<const PrebuiltSincFilterCoefficientTable> kPrebuiltSincFilterCoefficientTables

Defined at line 12 of file ../../src/media/audio/lib/processing/coefficient_table_data_empty.cc

const float kMinGainDb

Defined at line 14 of file ../../src/media/audio/lib/processing/gain.h

const bool kTracePositionEvents

Defined at line 15 of file ../../src/media/audio/lib/processing/flags.h

const float kMinGainScale

Defined at line 15 of file ../../src/media/audio/lib/processing/gain.h

const int8_t kMaxInt8

Defined at line 17 of file ../../src/media/audio/lib/format2/sample_converter.h

const bool kEnable4ChannelWorkaround

Defined at line 18 of file ../../src/media/audio/lib/format2/channel_mapper.h

const int8_t kMinInt8

Defined at line 18 of file ../../src/media/audio/lib/format2/sample_converter.h

const float kUnityGainDb

Defined at line 18 of file ../../src/media/audio/lib/processing/gain.h

const int32_t kFloatToInt8

Defined at line 19 of file ../../src/media/audio/lib/format2/sample_converter.h

const float kUnityGainScale

Defined at line 19 of file ../../src/media/audio/lib/processing/gain.h

const int32_t kInt8ToUint8

Defined at line 20 of file ../../src/media/audio/lib/format2/sample_converter.h

const bool kCheckPositionsAndRatesOrDie

Defined at line 20 of file ../../src/media/audio/lib/processing/flags.h

const float kInt8ToFloat

Defined at line 21 of file ../../src/media/audio/lib/format2/sample_converter.h

const int16_t kMaxInt16

Defined at line 24 of file ../../src/media/audio/lib/format2/sample_converter.h

const int16_t kMinInt16

Defined at line 25 of file ../../src/media/audio/lib/format2/sample_converter.h

const int32_t kFloatToInt16

Defined at line 26 of file ../../src/media/audio/lib/format2/sample_converter.h

const float kInt16ToFloat

Defined at line 27 of file ../../src/media/audio/lib/format2/sample_converter.h

const bool kEnableDisplayForPositionsAndRates

Defined at line 27 of file ../../src/media/audio/lib/processing/flags.h

const bool kLogFakeCodec

Defined at line 28 of file ../../src/media/audio/services/device_registry/testing/fakes/fake_codec.h

const int32_t kPtsFractionalBits

Defined at line 31 of file ../../src/media/audio/lib/format2/fixed.h

const bool kEnableDisplayForFilterTablesAndComputation

Defined at line 31 of file ../../src/media/audio/lib/processing/flags.h

const int32_t kMaxInt24

Defined at line 32 of file ../../src/media/audio/lib/format2/sample_converter.h

const int32_t kMinInt24

Defined at line 33 of file ../../src/media/audio/lib/format2/sample_converter.h

const int32_t kMaxInt24In32

Defined at line 34 of file ../../src/media/audio/lib/format2/sample_converter.h

const int32_t kMinInt24In32

Defined at line 35 of file ../../src/media/audio/lib/format2/sample_converter.h

const int32_t kFloatToInt24

Defined at line 36 of file ../../src/media/audio/lib/format2/sample_converter.h

const Fixed kOneFrame

Defined at line 37 of file ../../src/media/audio/lib/format2/fixed.h

const double kInt24ToFloat

Defined at line 37 of file ../../src/media/audio/lib/format2/sample_converter.h

const int64_t kFracOneFrame

Defined at line 38 of file ../../src/media/audio/lib/format2/fixed.h

const int64_t kFloatToInt24In32

Defined at line 38 of file ../../src/media/audio/lib/format2/sample_converter.h

const bool kLogMain

Defined at line 38 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogRoleManager

Defined at line 40 of file ../../src/media/audio/services/device_registry/logging.h

const Fixed kHalfFrame

Defined at line 41 of file ../../src/media/audio/lib/format2/fixed.h

const int64_t kFracHalfFrame

Defined at line 42 of file ../../src/media/audio/lib/format2/fixed.h

const bool kLogDeviceDetection

Defined at line 43 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogDeviceInitializationProgress

Defined at line 44 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogAudioDeviceRegistryMethods

Defined at line 45 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogDeviceAddErrorRemove

Defined at line 46 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogDeviceInfo

Defined at line 47 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogDriverCommandTimeouts

Defined at line 48 of file ../../src/media/audio/services/device_registry/logging.h

const bool kTraceInspector

Defined at line 50 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogObjectLifetimes

Defined at line 51 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogObjectCounts

Defined at line 52 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogDeviceState

Defined at line 55 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogSignalProcessingState

Defined at line 56 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogRingBufferState

Defined at line 57 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogDeviceMethods

Defined at line 59 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogNotifyMethods

Defined at line 60 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogRingBufferMethods

Defined at line 61 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogCodecFidlCalls

Defined at line 64 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogCodecFidlResponses

Defined at line 65 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogCodecFidlResponseValues

Defined at line 66 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogCompositeFidlCalls

Defined at line 68 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogCompositeFidlResponses

Defined at line 69 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogCompositeFidlResponseValues

Defined at line 70 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogSignalProcessingFidlCalls

Defined at line 72 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogSignalProcessingFidlResponses

Defined at line 73 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogSignalProcessingFidlResponseValues

Defined at line 74 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogRingBufferFidlCalls

Defined at line 76 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogRingBufferFidlResponses

Defined at line 77 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogRingBufferFidlResponseValues

Defined at line 78 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogControlCreatorServerMethods

Defined at line 81 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogControlCreatorServerResponses

Defined at line 82 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogControlServerMethods

Defined at line 84 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogControlServerResponses

Defined at line 85 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogObserverServerMethods

Defined at line 87 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogObserverServerResponses

Defined at line 88 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogProviderServerMethods

Defined at line 90 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogProviderServerResponses

Defined at line 91 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogRegistryServerMethods

Defined at line 93 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogRegistryServerResponses

Defined at line 94 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogRingBufferServerMethods

Defined at line 96 of file ../../src/media/audio/services/device_registry/logging.h

const bool kLogRingBufferServerResponses

Defined at line 97 of file ../../src/media/audio/services/device_registry/logging.h