Move some declarations to more appropriate headers

This commit is contained in:
Chris Robinson
2020-11-27 22:27:45 -08:00
parent 7e798df7b8
commit dbfdd35545
4 changed files with 25 additions and 18 deletions
+1 -6
View File
@@ -29,6 +29,7 @@
#include "hrtf.h"
#include "inprogext.h"
#include "intrusive_ptr.h"
#include "mixer/defs.h"
#include "vector.h"
class BFormatDec;
@@ -154,12 +155,6 @@ struct BFChannelConfig {
ALuint Index;
};
/* Maximum number of samples to pad on the ends of a buffer for resampling.
* Note that the padding is symmetric (half at the beginning and half at the
* end)!
*/
#define MAX_RESAMPLER_PADDING 48
struct MixParams {
/* Coefficient channel mapping for mixing to the buffer. */
+5 -8
View File
@@ -6,13 +6,15 @@
#include <cstddef>
#include <type_traits>
#include "AL/al.h"
#include "alcmain.h"
#include "alspan.h"
#include "ambidefs.h"
#include "core/bufferline.h"
#include "core/devformat.h"
struct ALCcontext;
struct ALCdevice;
struct ALeffectslot;
struct MixParams;
#define MAX_PITCH 10
@@ -37,11 +39,6 @@ constexpr float AirAbsorbGainHF{0.99426f}; /* -0.05dB */
constexpr float ReverbDecayGain{0.001f}; /* -60 dB */
constexpr int MixerFracBits{12};
constexpr int MixerFracOne{1 << MixerFracBits};
constexpr int MixerFracMask{MixerFracOne - 1};
inline float lerp(float val1, float val2, float mu) noexcept
{ return val1 + (val2-val1)*mu; }
inline float cubic(float val1, float val2, float val3, float val4, float mu) noexcept
+18 -4
View File
@@ -1,15 +1,29 @@
#ifndef MIXER_DEFS_H
#define MIXER_DEFS_H
#include "alcmain.h"
#include "alspan.h"
#include "alu.h"
#include "hrtf.h"
#include <array>
#include "alspan.h"
#include "core/bufferline.h"
struct DirectHrtfState;
struct HrtfFilter;
union InterpState;
struct MixHrtfFilter;
using uint = unsigned int;
using float2 = std::array<float,2>;
constexpr int MixerFracBits{12};
constexpr int MixerFracOne{1 << MixerFracBits};
constexpr int MixerFracMask{MixerFracOne - 1};
/* Maximum number of samples to pad on the ends of a buffer for resampling.
* Note that the padding is symmetric (half at the beginning and half at the
* end)!
*/
#define MAX_RESAMPLER_PADDING 48
template<typename TypeTag, typename InstTag>
+1
View File
@@ -12,6 +12,7 @@
#include "filters/nfc.h"
#include "filters/splitter.h"
#include "hrtf.h"
#include "mixer/defs.h"
struct EffectSlot;
struct BufferlistItem;