[feat] add config param to control use TURN or not

This commit is contained in:
dijunkun
2024-08-27 17:05:41 +08:00
parent 35f26283de
commit 0b0e61cdc4
8 changed files with 45 additions and 24 deletions

View File

@@ -37,6 +37,7 @@ typedef struct {
const char *turn_server_password;
bool hardware_acceleration;
bool av1_encoding;
bool enable_turn;
OnReceiveBuffer on_receive_video_buffer;
OnReceiveBuffer on_receive_audio_buffer;
@@ -99,6 +100,7 @@ class PeerConnection {
int turn_server_port_ = 0;
bool hardware_acceleration_ = false;
bool av1_encoding_ = false;
bool enable_turn_ = false;
bool trickle_ice_ = true;
TraversalMode mode_ = TraversalMode::P2P;