WebRTC support helpers

SympleSignaller

[SignallingInterface]({#ref classicy_1_1wrtc_1_1SignallingInterface #}) implementation using the Symple call protocol.

SympleSignaller

#include <icy/webrtc/support/symplesignaller.h>

Inherits: SignallingInterface

SignallingInterface implementation using the Symple call protocol.

Speaks the call:init, call:accept, call:reject, call:offer, call:answer, call:candidate, and call:hangup envelope over a connected Symple client.

The remote peer identifier on this signalling boundary is the full Symple address string (user|id).

Public Methods

ReturnNameDescription
SympleSignaller explicit
SympleSignallerDeleted constructor.
voidsendSdp virtualSend an SDP offer or answer to the remote peer.
voidsendCandidate virtualSend an ICE candidate to the remote peer.
voidsendControl virtualSend a control message to the remote peer.

SympleSignaller

explicit

explicit SympleSignaller(smpl::Client & client)

SympleSignaller

SympleSignaller(const SympleSignaller &) = delete

Deleted constructor.


sendSdp

virtual

virtual void sendSdp(const std::string & peerId, const std::string & type, const std::string & sdp)

Send an SDP offer or answer to the remote peer.

Parameters

  • peerId Remote peer identifier.

  • type "offer" or "answer".

  • sdp The SDP string.


sendCandidate

virtual

virtual void sendCandidate(const std::string & peerId, const std::string & candidate, const std::string & mid)

Send an ICE candidate to the remote peer.

Parameters

  • peerId Remote peer identifier.

  • candidate The candidate string (from RTCIceCandidate).

  • mid The sdpMid value.


sendControl

virtual

virtual void sendControl(const std::string & peerId, const std::string & type, const std::string & reason)

Send a control message to the remote peer.

Parameters

  • peerId Remote peer identifier.

  • type Control type: "init", "accept", "reject", "hangup".

  • reason Optional reason string (for reject/hangup).

Private Attributes

ReturnNameDescription
smpl::Client &_client

_client

smpl::Client & _client

Private Methods

ReturnNameDescription
voidonMessage
voidsend

onMessage

void onMessage(smpl::Message & msg)

send

void send(const std::string & action, const std::string & to, const json::Value & data)