kodi
VideoSyncWpPresentation.h
1 /*
2  * Copyright (C) 2017-2018 Team Kodi
3  * This file is part of Kodi - https://kodi.tv
4  *
5  * SPDX-License-Identifier: GPL-2.0-or-later
6  * See LICENSES/README.md for more information.
7  */
8 
9 #pragma once
10 
11 #include "Signals.h"
12 #include "windowing/VideoSync.h"
13 
14 #include <cstdint>
15 
16 namespace KODI
17 {
18 namespace WINDOWING
19 {
20 namespace WAYLAND
21 {
22 
23 class CWinSystemWayland;
24 
26 {
27 public:
29 
30  float GetFps() override;
31  bool Setup() override;
32  void Run(CEvent& stop) override;
33  void Cleanup() override;
34 
35 private:
36  void HandlePresentation(timespec tv, std::uint32_t refresh, std::uint32_t syncOutputID, float syncOutputRefreshRate, std::uint64_t msc);
37 
38  CEvent m_stopEvent;
39  CSignalRegistration m_presentationHandler;
40  std::uint64_t m_lastMsc{};
41  std::uint32_t m_syncOutputID{};
42  CWinSystemWayland &m_winSystem;
43 };
44 
45 }
46 }
47 }
This is an Event class built from a ConditionVariable.
Definition: Event.h:35
Definition: WinSystemWayland.h:47
Definition: AudioDecoder.h:18
Definition: VideoSyncWpPresentation.h:25
Definition: VideoReferenceClock.h:19
Definition: Signals.h:31
Definition: VideoSync.h:15