![]() |
Sunshine latest
Self-hosted game stream host for Moonlight.
|
Definitions for Windows mDNS service registration. More...
#include <winsock2.h>
#include <windows.h>
#include <windns.h>
#include <winerror.h>
#include "misc.h"
#include "src/config.h"
#include "src/logging.h"
#include "src/network.h"
#include "src/nvhttp.h"
#include "src/platform/common.h"
#include "src/thread_safe.h"
Classes | |
struct | _DNS_SERVICE_CANCEL |
struct | _DNS_SERVICE_INSTANCE |
struct | _DNS_SERVICE_REGISTER_REQUEST |
class | platf::publish::mdns_registration_t |
Macros | |
#define | __SV(quote) L##quote##sv |
#define | _FN(x, ret, args) |
#define | SERVICE_DOMAIN "local" |
#define | SV(quote) __SV(quote) |
Typedefs | |
typedef DWORD(* | _DnsServiceDeRegister_fn) (_In_ PDNS_SERVICE_REGISTER_REQUEST pRequest, _Inout_opt_ PDNS_SERVICE_CANCEL pCancel) |
typedef VOID(* | _DnsServiceFreeInstance_fn) (_In_ PDNS_SERVICE_INSTANCE pInstance) |
typedef DWORD(* | _DnsServiceRegister_fn) (_In_ PDNS_SERVICE_REGISTER_REQUEST pRequest, _Inout_opt_ PDNS_SERVICE_CANCEL pCancel) |
typedef struct _DNS_SERVICE_CANCEL | DNS_SERVICE_CANCEL |
typedef struct _DNS_SERVICE_INSTANCE | DNS_SERVICE_INSTANCE |
typedef VOID WINAPI | DNS_SERVICE_REGISTER_COMPLETE(_In_ DWORD Status, _In_ PVOID pQueryContext, _In_ PDNS_SERVICE_INSTANCE pInstance) |
typedef struct _DNS_SERVICE_REGISTER_REQUEST | DNS_SERVICE_REGISTER_REQUEST |
typedef struct _DNS_SERVICE_CANCEL * | PDNS_SERVICE_CANCEL |
typedef struct _DNS_SERVICE_INSTANCE * | PDNS_SERVICE_INSTANCE |
typedef DNS_SERVICE_REGISTER_COMPLETE * | PDNS_SERVICE_REGISTER_COMPLETE |
typedef struct _DNS_SERVICE_REGISTER_REQUEST * | PDNS_SERVICE_REGISTER_REQUEST |
Functions | |
int | platf::publish::load_funcs (HMODULE handle) |
VOID WINAPI | platf::publish::register_cb (DWORD status, PVOID pQueryContext, PDNS_SERVICE_INSTANCE pInstance) |
std::unique_ptr< deinit_t > | platf::publish::start () |
Main entry point for publication of our service on macOS. | |
Definitions for Windows mDNS service registration.
#define _FN | ( | x, | |
ret, | |||
args ) |
std::unique_ptr<::platf::deinit_t > platf::publish::start | ( | ) |
Main entry point for publication of our service on macOS.
This function initiates a connection to the macOS mDNS service and requests to register our Sunshine service. Registration will occur asynchronously (unless it fails immediately, which is probably only possible if the host machine is misconfigured).
nullptr
(if the registration fails immediately) or a uniqur_ptr<deinit_t>
, which will manage polling for a response from the mDNS service, and then, when deconstructed, will deregister the service.