mirror of
https://github.com/mudita/MuditaOS.git
synced 2026-07-29 01:08:43 -04:00
* [EGD-558][fix] change error to info * [EGD-558] added volume control of currently active audio operation * [EGD-558] added ringing on incoming call * [EGD-558] mini clean up in callwindow * [EGD-558] removed reinterpret_casts and added some logging * [EGD-558] rewritten methods to increment/decrement volume * [EGD-558] clean up * [EGD-558] moved volume control to application class added nullptr checks * [EGD-558] fixed types * [EGD-558] added some audio debug logs * [EGD-558] left a comment why ringing sound is currently disabled * [EGD-558] PR fixes * [EGD-558] PR fix * [EGD-558] added propper error codes on pointer checking in Audio.cpp
37 lines
821 B
C++
37 lines
821 B
C++
#pragma once
|
|
|
|
namespace audio
|
|
{
|
|
using Position = float;
|
|
using Volume = float;
|
|
using Gain = float;
|
|
|
|
constexpr Volume defaultVolumeStep = 0.1;
|
|
constexpr Gain defaultGainStep = 1.0;
|
|
constexpr Volume invalidVolume = -1.0;
|
|
constexpr Gain invalidGain = -1.0;
|
|
constexpr Volume defaultVolume = 0.5;
|
|
constexpr Gain defaultGain = 0.5;
|
|
|
|
enum class RetCode
|
|
{
|
|
Success = 0,
|
|
InvokedInIncorrectState,
|
|
UnsupportedProfile,
|
|
UnsupportedEvent,
|
|
InvalidFormat,
|
|
OperationCreateFailed,
|
|
FileDoesntExist,
|
|
FailedToAllocateMemory,
|
|
OperationNotSet,
|
|
ProfileNotSet,
|
|
Failed
|
|
};
|
|
|
|
enum class AudioEvents
|
|
{
|
|
EndOfFile,
|
|
FileSystemNoSpace
|
|
};
|
|
} // namespace audio
|