qaudio.sip 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. // qaudio.sip generated by MetaSIP
  2. //
  3. // This file is part of the QtMultimedia Python extension module.
  4. //
  5. // Copyright (c) 2026 Riverbank Computing Limited <info@riverbankcomputing.com>
  6. //
  7. // This file is part of PyQt6.
  8. //
  9. // This file may be used under the terms of the GNU General Public License
  10. // version 3.0 as published by the Free Software Foundation and appearing in
  11. // the file LICENSE included in the packaging of this file. Please review the
  12. // following information to ensure the GNU General Public License version 3.0
  13. // requirements will be met: http://www.gnu.org/copyleft/gpl.html.
  14. //
  15. // If you do not wish to use this file under the terms of the GPL version 3.0
  16. // then you may purchase a commercial license. For more information contact
  17. // info@riverbankcomputing.com.
  18. //
  19. // This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
  20. // WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
  21. %If (Qt_6_2_0 -)
  22. // Deprecated (and aliased to QtAudio) in Qt v6.7 but retained for compatibility.
  23. // We also ignore any methods that refer to QtAudio.
  24. namespace QAudio
  25. {
  26. %TypeHeaderCode
  27. #include <qaudio.h>
  28. %End
  29. enum Error
  30. {
  31. NoError,
  32. OpenError,
  33. IOError,
  34. UnderrunError,
  35. FatalError,
  36. };
  37. enum State
  38. {
  39. ActiveState,
  40. SuspendedState,
  41. StoppedState,
  42. IdleState,
  43. };
  44. enum VolumeScale
  45. {
  46. LinearVolumeScale,
  47. CubicVolumeScale,
  48. LogarithmicVolumeScale,
  49. DecibelVolumeScale,
  50. };
  51. float convertVolume(float volume, QAudio::VolumeScale from, QAudio::VolumeScale to);
  52. };
  53. %End
  54. %PostInitialisationCode
  55. // Implement QtAudio as an alternative name to QAudio.
  56. PyObject *qaudio = PyDict_GetItemString(sipModuleDict, sipName_QAudio);
  57. if (qaudio && PyDict_SetItemString(sipModuleDict, "QtAudio", qaudio) == 0)
  58. Py_INCREF(qaudio);
  59. %End