RetroArch
Classes | Functions | Variables
netplay_discovery.c File Reference
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <string/stdstring.h>
#include <file/file_path.h>
#include "../../file_path_special.h"
#include "../../paths.h"
#include "../../content.h"
#include <compat/strl.h>
#include <net/net_compat.h>
#include "../../retroarch.h"
#include "../../version.h"
#include "../../verbosity.h"
#include "netplay.h"
#include "netplay_discovery.h"
#include "netplay_private.h"
Include dependency graph for netplay_discovery.c:

Classes

struct  ad_packet
 

Functions

static bool netplay_lan_ad_client (void)
 
struct netplay_roomnetplay_get_host_room (void)
 
bool init_netplay_discovery (void)
 
void deinit_netplay_discovery (void)
 
bool netplay_discovery_driver_ctl (enum rarch_netplay_discovery_ctl_state state, void *data)
 
static bool init_lan_ad_server_socket (netplay_t *netplay, uint16_t port)
 
bool netplay_lan_ad_server (netplay_t *netplay)
 

Variables

static int lan_ad_server_fd = -1
 
static int lan_ad_client_fd = -1
 
int netplay_room_count = 0
 
struct netplay_roomnetplay_room_list = NULL
 
static struct ad_packet ad_packet_buffer
 
static struct netplay_host_list discovered_hosts
 
static size_t discovered_hosts_allocated
 
static struct netplay_room netplay_host_room = {0}
 

Function Documentation

◆ deinit_netplay_discovery()

void deinit_netplay_discovery ( void  )

Deinitialize and free Netplay discovery

Here is the call graph for this function:

◆ init_lan_ad_server_socket()

static bool init_lan_ad_server_socket ( netplay_t netplay,
uint16_t  port 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ init_netplay_discovery()

bool init_netplay_discovery ( void  )

Initialize Netplay discovery (client)

Here is the call graph for this function:
Here is the caller graph for this function:

◆ netplay_discovery_driver_ctl()

bool netplay_discovery_driver_ctl ( enum rarch_netplay_discovery_ctl_state  state,
void data 
)

Discovery control

Here is the call graph for this function:
Here is the caller graph for this function:

◆ netplay_get_host_room()

struct netplay_room* netplay_get_host_room ( void  )
Here is the caller graph for this function:

◆ netplay_lan_ad_client()

static bool netplay_lan_ad_client ( void  )
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ netplay_lan_ad_server()

bool netplay_lan_ad_server ( netplay_t netplay)

netplay_lan_ad_server

Respond to any LAN ad queries that the netplay server has received.

Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ ad_packet_buffer

struct ad_packet ad_packet_buffer
static

◆ discovered_hosts

struct netplay_host_list discovered_hosts
static

◆ discovered_hosts_allocated

size_t discovered_hosts_allocated
static

◆ lan_ad_client_fd

int lan_ad_client_fd = -1
static

◆ lan_ad_server_fd

int lan_ad_server_fd = -1
static

◆ netplay_host_room

struct netplay_room netplay_host_room = {0}
static

◆ netplay_room_count

int netplay_room_count = 0

◆ netplay_room_list

struct netplay_room* netplay_room_list = NULL