8 #include "aloptional.h"
9 #include "core/ambidefs.h"
11 /* Helpers to read .ambdec configuration files. */
13 enum class AmbDecScale
{
19 std::string Description
;
20 int Version
{0}; /* Must be 3 */
22 unsigned int ChanMask
{0u};
23 unsigned int FreqBands
{0u}; /* Must be 1 or 2 */
24 AmbDecScale CoeffScale
{};
26 float XOverFreq
{0.0f
};
27 float XOverRatio
{0.0f
};
33 float Elevation
{0.0f
};
34 std::string Connection
;
36 size_t NumSpeakers
{0};
37 std::unique_ptr
<SpeakerConf
[]> Speakers
;
39 using CoeffArray
= std::array
<float,MaxAmbiChannels
>;
40 std::unique_ptr
<CoeffArray
[]> Matrix
;
42 /* Unused when FreqBands == 1 */
43 float LFOrderGain
[MaxAmbiOrder
+1]{};
46 float HFOrderGain
[MaxAmbiOrder
+1]{};
49 al::optional
<std::string
> load(const char *fname
) noexcept
;
52 #endif /* CORE_AMBDEC_H */