Add/Move helpers to register OBS websocket vendor requests

Adds websocket vendor requests to start and stop the plugin.
Adds vendor events to indicate when the plugin is started or stopped.

These are ntended to be used for the StreamDeck plugin support.
This commit is contained in:
WarmUpTill
2024-09-01 22:15:25 +02:00
committed by WarmUpTill
parent 624b841ca1
commit 91912f2aa5
6 changed files with 201 additions and 69 deletions

View File

@@ -0,0 +1,17 @@
#pragma once
#include "export-symbol-helper.hpp"
#include <functional>
#include <obs-data.h>
#include <string>
namespace advss {
EXPORT const char *GetWebsocketVendorName();
EXPORT void RegisterWebsocketRequest(
const std::string &name,
const std::function<void(obs_data_t *, obs_data_t *)> &callback);
EXPORT void SendWebsocketVendorEvent(const std::string &eventName,
obs_data_t *data);
} // namespace advss