4#ifndef QPIPEWIRE_ASYNC_SUPPORT_P_H
5#define QPIPEWIRE_ASYNC_SUPPORT_P_H
18#include <QtCore/qglobal.h>
19#include <QtCore/qsemaphore.h>
20#include <QtCore/private/qexpected_p.h>
24#include <spa/utils/hook.h>
50 uint32_t ,
const struct spa_pod * )>;
67 static void onInfo(
void *userData,
const struct pw_node_info *);
68 static void onParam(
void *userData,
int seq, uint32_t id, uint32_t index, uint32_t next,
69 const struct spa_pod *);
88 std::function<
void()> m_handler;
95 std::optional<std::chrono::nanoseconds> timeout = {});
98 QSemaphore m_semaphore;
static bool isInPwThreadLoop()
static std::atomic_int s_sequenceNumberAllocator
std::error_code make_error_code(int errnoValue=errno)
q23::expected< void, int > asyncWait(pw_core *coreConnection, std::function< void()> handler)
pw_core_events coreEvents
q23::expected< bool, int > sync(pw_core *coreConnection, std::optional< std::chrono::nanoseconds > timeout={})
ParamHandler paramHandler
NodeEventListener(PwNodeHandle, NodeHandler)
std::function< void(const struct pw_node_info *)> InfoHandler
void enumParams(spa_param_type)
std::function< void(int, uint32_t, uint32_t, uint32_t, const struct spa_pod *)> ParamHandler