Hermes 0.7.0
Linux game streaming host
Loading...
Searching...
No Matches
hermes_kms_capture.h File Reference

Hermes-KMS scanout readiness shared by capture and its regression tests. More...

#include <algorithm>
#include <cerrno>
#include <chrono>
#include <cstdint>
#include <limits>
Include dependency graph for hermes_kms_capture.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  VDISPLAY::hermes_kms::status_t

Functions

template<class Query, class Now, class SleepUntil>
int VDISPLAY::hermes_kms::wait_for_scanout (int &width, int &height, std::chrono::milliseconds timeout, Query query, Now now, SleepUntil sleep_until)

Variables

constexpr uint64_t VDISPLAY::hermes_kms::status_output_enabled = 1ULL << 0
constexpr uint64_t VDISPLAY::hermes_kms::status_connected = 1ULL << 1
constexpr uint64_t VDISPLAY::hermes_kms::status_scanout_active = 1ULL << 2
constexpr uint64_t VDISPLAY::hermes_kms::status_frame_valid = 1ULL << 3
constexpr uint64_t VDISPLAY::hermes_kms::status_dmabuf_export_ready = 1ULL << 4

Detailed Description

Hermes-KMS scanout readiness shared by capture and its regression tests.

Definition in file hermes_kms_capture.h.

Function Documentation

◆ wait_for_scanout()

template<class Query, class Now, class SleepUntil>
int VDISPLAY::hermes_kms::wait_for_scanout ( int & width,
int & height,
std::chrono::milliseconds timeout,
Query query,
Now now,
SleepUntil sleep_until )

Wait for a real scanout, not merely the mode accepted at hotplug time. Query returns zero or an errno; clock/sleep injection keeps the deadline and delayed-compositor tests deterministic without touching a live display. A zero timeout performs one query, for callers with their own polling loop.

Definition at line 62 of file hermes_kms_capture.h.

Variable Documentation

◆ status_connected

uint64_t VDISPLAY::hermes_kms::status_connected = 1ULL << 1
constexpr

Definition at line 16 of file hermes_kms_capture.h.

◆ status_dmabuf_export_ready

uint64_t VDISPLAY::hermes_kms::status_dmabuf_export_ready = 1ULL << 4
constexpr

Definition at line 19 of file hermes_kms_capture.h.

◆ status_frame_valid

uint64_t VDISPLAY::hermes_kms::status_frame_valid = 1ULL << 3
constexpr

Definition at line 18 of file hermes_kms_capture.h.

◆ status_output_enabled

uint64_t VDISPLAY::hermes_kms::status_output_enabled = 1ULL << 0
constexpr

Definition at line 15 of file hermes_kms_capture.h.

◆ status_scanout_active

uint64_t VDISPLAY::hermes_kms::status_scanout_active = 1ULL << 2
constexpr

Definition at line 17 of file hermes_kms_capture.h.