|
AlexaClientSDK
1.26.0
A cross-platform, modular SDK for interacting with the Alexa Voice Service
|
Go to the documentation of this file.
16 #ifndef ALEXA_CLIENT_SDK_CAPABILITYAGENTS_SPEAKERMANAGER_INCLUDE_SPEAKERMANAGER_CHANNELVOLUMEMANAGER_H_
17 #define ALEXA_CLIENT_SDK_CAPABILITYAGENTS_SPEAKERMANAGER_INCLUDE_SPEAKERMANAGER_CHANNELVOLUMEMANAGER_H_
23 namespace capabilityAgents {
24 namespace speakerManager {
40 static std::shared_ptr<ChannelVolumeManager>
create(
41 std::shared_ptr<avsCommon::sdkInterfaces::SpeakerInterface> speaker,
44 std::function<int8_t(int8_t)> volumeCurve =
nullptr);
49 size_t getId()
const override;
53 bool setMute(
bool mute)
override;
65 using VolumeCurveFunction = std::function<int8_t(int8_t unduckedVolume)>;
74 std::shared_ptr<avsCommon::sdkInterfaces::SpeakerInterface> speaker,
76 VolumeCurveFunction volumeCurve);
97 static int8_t defaultVolumeAttenuateFunction(int8_t unduckedVolume);
100 mutable std::mutex m_mutex;
103 std::shared_ptr<avsCommon::sdkInterfaces::SpeakerInterface> m_speaker;
109 int8_t m_unduckedVolume;
112 VolumeCurveFunction m_volumeCurveFunction;
121 #endif // ALEXA_CLIENT_SDK_CAPABILITYAGENTS_SPEAKERMANAGER_INCLUDE_SPEAKERMANAGER_CHANNELVOLUMEMANAGER_H_
size_t getId() const override
Definition: ChannelVolumeManager.cpp:92
Definition: SpeakerInterface.h:42
bool setMute(bool mute) override
Definition: ChannelVolumeManager.cpp:159
avsCommon::sdkInterfaces::ChannelVolumeInterface::Type getSpeakerType() const override
Definition: ChannelVolumeManager.cpp:87
@ AVS_SPEAKER_VOLUME
Volume type reflecting AVS Speaker API volume.
bool startDucking() override
Definition: ChannelVolumeManager.cpp:96
bool getSpeakerSettings(avsCommon::sdkInterfaces::SpeakerInterface::SpeakerSettings *settings) const override
Definition: ChannelVolumeManager.cpp:165
Whether or not curl logs should be emitted.
Definition: AVSConnectionManager.h:36
Definition: ChannelVolumeManager.h:30
Definition: ChannelVolumeInterface.h:32
bool setUnduckedVolume(int8_t volume) override
Definition: ChannelVolumeManager.cpp:139
static std::shared_ptr< ChannelVolumeManager > create(std::shared_ptr< avsCommon::sdkInterfaces::SpeakerInterface > speaker, avsCommon::sdkInterfaces::ChannelVolumeInterface::Type type=avsCommon::sdkInterfaces::ChannelVolumeInterface::Type::AVS_SPEAKER_VOLUME, std::function< int8_t(int8_t)> volumeCurve=nullptr)
Definition: ChannelVolumeManager.cpp:52
bool stopDucking() override
Definition: ChannelVolumeManager.cpp:120
Type
Definition: ChannelVolumeInterface.h:37
AlexaClientSDK 1.26.0 - Copyright 2016-2022 Amazon.com, Inc. or its affiliates. All Rights Reserved.
Licensed under the Apache License, Version 2.0