qmediatimerange.sip 3.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. // qmediatimerange.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. class QMediaTimeRange
  23. {
  24. %TypeHeaderCode
  25. #include <qmediatimerange.h>
  26. %End
  27. public:
  28. QMediaTimeRange();
  29. QMediaTimeRange(const QMediaTimeRange::Interval &);
  30. QMediaTimeRange(qint64 start, qint64 end);
  31. QMediaTimeRange(const QMediaTimeRange &range);
  32. ~QMediaTimeRange();
  33. qint64 earliestTime() const;
  34. qint64 latestTime() const;
  35. QList<QMediaTimeRange::Interval> intervals() const;
  36. bool isEmpty() const;
  37. bool isContinuous() const;
  38. bool contains(qint64 time) const;
  39. void addInterval(const QMediaTimeRange::Interval &interval);
  40. void addInterval(qint64 start, qint64 end);
  41. void addTimeRange(const QMediaTimeRange &);
  42. void removeInterval(const QMediaTimeRange::Interval &interval);
  43. void removeInterval(qint64 start, qint64 end);
  44. void removeTimeRange(const QMediaTimeRange &);
  45. QMediaTimeRange &operator+=(const QMediaTimeRange::Interval &);
  46. QMediaTimeRange &operator+=(const QMediaTimeRange &);
  47. QMediaTimeRange &operator-=(const QMediaTimeRange::Interval &);
  48. QMediaTimeRange &operator-=(const QMediaTimeRange &);
  49. void clear();
  50. struct Interval
  51. {
  52. %TypeHeaderCode
  53. #include <qmediatimerange.h>
  54. %End
  55. Interval(qint64 start, qint64 end);
  56. qint64 start() const;
  57. qint64 end() const;
  58. bool contains(qint64 time) const;
  59. bool isNormal() const;
  60. QMediaTimeRange::Interval normalized() const;
  61. QMediaTimeRange::Interval translated(qint64 offset) const;
  62. };
  63. };
  64. %End
  65. %If (Qt_6_2_0 -)
  66. bool operator==(const QMediaTimeRange &, const QMediaTimeRange &);
  67. %End
  68. %If (Qt_6_2_0 -)
  69. bool operator!=(const QMediaTimeRange &, const QMediaTimeRange &);
  70. %End
  71. %If (Qt_6_2_0 -)
  72. QMediaTimeRange operator+(const QMediaTimeRange &, const QMediaTimeRange &);
  73. %End
  74. %If (Qt_6_2_0 -)
  75. QMediaTimeRange operator-(const QMediaTimeRange &, const QMediaTimeRange &);
  76. %End
  77. %If (Qt_6_2_0 -)
  78. bool operator==(QMediaTimeRange::Interval lhs, QMediaTimeRange::Interval rhs);
  79. %End
  80. %If (Qt_6_2_0 -)
  81. bool operator!=(QMediaTimeRange::Interval lhs, QMediaTimeRange::Interval rhs);
  82. %End