Make a couple lambdas static
[openal-soft.git] / utils / sofa-support.h
blobe73037b435fcfd819d88930e774a2b44a26eed18
1 #ifndef UTILS_SOFA_SUPPORT_H
2 #define UTILS_SOFA_SUPPORT_H
4 #include <cstddef>
5 #include <memory>
6 #include <vector>
8 #include "alspan.h"
10 #include "mysofa.h"
13 struct MySofaDeleter {
14 void operator()(MYSOFA_HRTF *sofa) { mysofa_free(sofa); }
16 using MySofaHrtfPtr = std::unique_ptr<MYSOFA_HRTF,MySofaDeleter>;
18 // Per-field measurement info.
19 struct SofaField {
20 using uint = unsigned int;
22 double mDistance{0.0};
23 uint mEvCount{0u};
24 uint mEvStart{0u};
25 std::vector<uint> mAzCounts;
28 const char *SofaErrorStr(int err);
30 auto GetCompatibleLayout(al::span<const float> xyzs) -> std::vector<SofaField>;
32 #endif /* UTILS_SOFA_SUPPORT_H */