uvgRTP 2.3.0
An open-source library for RTP/SRTP media delivery
Loading...
Searching...
No Matches
context.hh
1#pragma once
2
3#include "util.hh"
4
5#include <map>
6#include <string>
7
8
9namespace uvgrtp {
10
11 class session;
12
16 class context {
17 public:
25
33
44 uvgrtp::session *create_session(std::string address);
45
62 uvgrtp::session *create_session(std::string remote_addr, std::string local_addr);
63
75
77 std::string& get_cname();
79
86 bool crypto_enabled() const;
87
88 private:
89 /* Generate CNAME for participant using host and login names */
90 std::string generate_cname() const;
91
92 /* CNAME is the same for all connections */
93 std::string cname_;
94 };
95}
96
97namespace uvg_rtp = uvgrtp;
Provides CNAME isolation and can be used to create uvgrtp::session objects.
Definition: context.hh:16
bool crypto_enabled() const
Has Crypto++ been included in uvgRTP library.
rtp_error_t destroy_session(uvgrtp::session *session)
Destroy RTP session and all of its media streams.
~context()
RTP context destructor.
uvgrtp::session * create_session(std::string remote_addr, std::string local_addr)
Create a new RTP session.
uvgrtp::session * create_session(std::string address)
Create a new RTP session.
context()
RTP context constructor.
Provides ZRTP synchronization and can be used to create uvgrtp::media_stream objects.
Definition: session.hh:26