Top | ![]() |
![]() |
![]() |
![]() |
GstSyncControlServerGstSyncControlServer — Interface for the implementation of the network transport used by GstSyncServer. |
The GstSyncControlServer interface allows users of this library to provide a custom implementation of the network transport that is used to send clients information required to set up synchronised playback.
The interface constists of:
The GstSyncControlServer:address and GstSyncControlServer:port properties to specify the network address for the server implementation to listen on.
The GstSyncControlServer:sync-info property which is set by GstSyncServer every time new information needs to be sent to clients (both existing, and ones that join later).
The GstSyncControlServer::start and GstSyncControlServer::stop signals that are used to have the server start/stop listening for connections and sending information.
The specifics of how connections from clients are received, and how data is sent is entirely up to the implementation. It is expected that clients will use a corresponding GstSyncControlClient implementation.
gchar *
gst_sync_control_server_get_address (GstSyncControlServer *server
);
void gst_sync_control_server_set_address (GstSyncControlServer *server
,const gchar *address
);
Sets the network address for server
to listen on.
guint
gst_sync_control_server_get_port (GstSyncControlServer *server
);
void gst_sync_control_server_set_port (GstSyncControlServer *server
,guint port
);
Sets the network port for server
to listen on.
void gst_sync_control_server_set_sync_info (GstSyncControlServer *server
,const GstSyncServerInfo *info
);
Provides an updated GstSyncServerInfo to server
to distribute to all
connected clients (and new clients when they connect).
“address”
property“address” gchar *
The network address for the control server to listen on.
Flags: Read / Write / Construct
Default value: NULL
“port”
property“port” gint
The network port for the control server to listen on.
Flags: Read / Write / Construct
Allowed values: [0,65535]
Default value: 0
“sync-info”
property“sync-info” GstSyncServerInfo *
Set whenever updated synchronisation information should be sent. The data is a GstSyncServerInfo, which is fairly easy to serialise as JSON.
Flags: Read / Write / Construct
“start”
signalgboolean user_function (GstSyncControlServer *arg0, gpointer arg1, gpointer user_data)
Start listening for connections from clients.
Flags: Action
“stop”
signalvoid user_function (GstSyncControlServer *arg0, gpointer user_data)
Disconnect all clients and stop listening for new connections.
Flags: Action