au88x0_xtalk.h 2.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. /***************************************************************************
  2. * au88x0_cxtalk.h
  3. *
  4. * Wed Nov 19 19:07:17 2003
  5. * Copyright 2003 mjander
  6. * mjander@users.sourceforge.org
  7. ****************************************************************************/
  8. /*
  9. * This program is free software; you can redistribute it and/or modify
  10. * it under the terms of the GNU General Public License as published by
  11. * the Free Software Foundation; either version 2 of the License, or
  12. * (at your option) any later version.
  13. *
  14. * This program is distributed in the hope that it will be useful,
  15. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  16. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  17. * GNU Library General Public License for more details.
  18. *
  19. * You should have received a copy of the GNU General Public License
  20. * along with this program; if not, write to the Free Software
  21. * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
  22. */
  23. /* The crosstalk canceler supports 5 stereo input channels. The result is
  24. available at one single output route pair (stereo). */
  25. #ifndef _AU88X0_CXTALK_H
  26. #define _AU88X0_CXTALK_H
  27. #include "au88x0.h"
  28. #define XTDLINE_SZ 32
  29. #define XTGAINS_SZ 10
  30. #define XTINST_SZ 4
  31. #define XT_HEADPHONE 1
  32. #define XT_SPEAKER0 2
  33. #define XT_SPEAKER1 3
  34. #define XT_DIAMOND 4
  35. typedef u32 xtalk_dline_t[XTDLINE_SZ];
  36. typedef u16 xtalk_gains_t[XTGAINS_SZ];
  37. typedef u16 xtalk_instate_t[XTINST_SZ];
  38. typedef u16 xtalk_coefs_t[5][5];
  39. typedef u16 xtalk_state_t[5][4];
  40. static void vortex_XtalkHw_SetGains(vortex_t * vortex,
  41. xtalk_gains_t const gains);
  42. static void vortex_XtalkHw_SetGainsAllChan(vortex_t * vortex);
  43. static void vortex_XtalkHw_SetSampleRate(vortex_t * vortex, u32 sr);
  44. static void vortex_XtalkHw_ProgramPipe(vortex_t * vortex);
  45. static void vortex_XtalkHw_ProgramPipe(vortex_t * vortex);
  46. static void vortex_XtalkHw_ProgramXtalkWide(vortex_t * vortex);
  47. static void vortex_XtalkHw_ProgramXtalkNarrow(vortex_t * vortex);
  48. static void vortex_XtalkHw_ProgramDiamondXtalk(vortex_t * vortex);
  49. static void vortex_XtalkHw_Enable(vortex_t * vortex);
  50. static void vortex_XtalkHw_Disable(vortex_t * vortex);
  51. static void vortex_XtalkHw_init(vortex_t * vortex);
  52. #endif /* _AU88X0_CXTALK_H */