Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

45 lines
1.0 KiB

  1. //--------------------------------------------------------------------------;
  2. //
  3. // File: decibels.cpp
  4. //
  5. // Copyright (c) 1995 - 1996 Microsoft Corporation. All Rights Reserved.
  6. //
  7. // Abstract:
  8. //
  9. // utilities for converting volume/pan in decibel units to/from
  10. // the 0-0xffff (0-1000) range used by waveOutSetVolume (MCI) etc
  11. //
  12. // Contents:
  13. //
  14. // History:
  15. // 06/15/95 SteveDav plagiarised from Direct Sound
  16. //
  17. //--------------------------------------------------------------------------;
  18. #ifdef __cplusplus
  19. extern "C" {
  20. #endif // __cplusplus
  21. #ifndef _AMOVIE_DB_
  22. #define AMOVIEAPI_DB DECLSPEC_IMPORT
  23. #else
  24. #define AMOVIEAPI_DB
  25. #endif
  26. AMOVIEAPI_DB LONG WINAPI AmpFactorToDB( DWORD dwFactor );
  27. AMOVIEAPI_DB DWORD WINAPI DBToAmpFactor( LONG lDB );
  28. #ifdef __cplusplus
  29. }
  30. #endif // __cplusplus
  31. #define AX_MIN_VOLUME -10000
  32. #define AX_QUARTER_VOLUME -1200
  33. #define AX_HALF_VOLUME -600
  34. #define AX_THREEQUARTERS_VOLUME -240
  35. #define AX_MAX_VOLUME 0
  36. #define AX_BALANCE_LEFT -10000
  37. #define AX_BALANCE_RIGHT 10000
  38. #define AX_BALANCE_NEUTRAL 0