MixFuncTable.h 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. /*
  2. * MixFuncTable.h
  3. * --------------
  4. * Purpose: Table containing all mixer functions.
  5. * Notes : (currently none)
  6. * Authors: OpenMPT Devs
  7. * The OpenMPT source code is released under the BSD license. Read LICENSE for more details.
  8. */
  9. #pragma once
  10. #include "openmpt/all/BuildSettings.hpp"
  11. #include "MixerInterface.h"
  12. OPENMPT_NAMESPACE_BEGIN
  13. namespace MixFuncTable
  14. {
  15. // Table index bits:
  16. // [b1-b0] format (8-bit-mono, 16-bit-mono, 8-bit-stereo, 16-bit-stereo)
  17. // [b2] ramp
  18. // [b3] filter
  19. // [b6-b4] src type
  20. // Sample type / processing type index
  21. enum FunctionIndex
  22. {
  23. ndx16Bit = 0x01,
  24. ndxStereo = 0x02,
  25. ndxRamp = 0x04,
  26. ndxFilter = 0x08,
  27. };
  28. // SRC index
  29. enum ResamplingIndex
  30. {
  31. ndxNoInterpolation = 0x00,
  32. ndxLinear = 0x10,
  33. ndxFastSinc = 0x20,
  34. ndxKaiser = 0x30,
  35. ndxFIRFilter = 0x40,
  36. ndxAmigaBlep = 0x50,
  37. };
  38. extern const MixFuncInterface Functions[6 * 16];
  39. ResamplingIndex ResamplingModeToMixFlags(ResamplingMode resamplingMode);
  40. }
  41. OPENMPT_NAMESPACE_END