Fix voice, voice_udp features
This commit is contained in:
parent
7554f90187
commit
ebcb6b65e4
|
@ -6,7 +6,6 @@
|
||||||
|
|
||||||
use std::collections::HashMap;
|
use std::collections::HashMap;
|
||||||
|
|
||||||
use log::{self, debug};
|
|
||||||
use reqwest::{Client, RequestBuilder, Response};
|
use reqwest::{Client, RequestBuilder, Response};
|
||||||
use serde::Deserialize;
|
use serde::Deserialize;
|
||||||
use serde_json::from_str;
|
use serde_json::from_str;
|
||||||
|
|
|
@ -2,9 +2,10 @@
|
||||||
// License, v. 2.0. If a copy of the MPL was not distributed with this
|
// License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||||
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||||
|
|
||||||
|
use pubserve::Publisher;
|
||||||
|
|
||||||
use crate::{
|
use crate::{
|
||||||
errors::VoiceGatewayError,
|
errors::VoiceGatewayError,
|
||||||
gateway::GatewayEvent,
|
|
||||||
types::{
|
types::{
|
||||||
SessionDescription, SessionUpdate, Speaking, SsrcDefinition, VoiceBackendVersion,
|
SessionDescription, SessionUpdate, Speaking, SsrcDefinition, VoiceBackendVersion,
|
||||||
VoiceClientConnectFlags, VoiceClientConnectPlatform, VoiceClientDisconnection,
|
VoiceClientConnectFlags, VoiceClientConnectPlatform, VoiceClientDisconnection,
|
||||||
|
|
|
@ -6,6 +6,7 @@ use std::{sync::Arc, time::Duration};
|
||||||
|
|
||||||
use log::*;
|
use log::*;
|
||||||
|
|
||||||
|
use pubserve::Publisher;
|
||||||
use tokio::sync::Mutex;
|
use tokio::sync::Mutex;
|
||||||
|
|
||||||
use futures_util::SinkExt;
|
use futures_util::SinkExt;
|
||||||
|
@ -16,7 +17,6 @@ use crate::gateway::Stream;
|
||||||
use crate::gateway::WebSocketBackend;
|
use crate::gateway::WebSocketBackend;
|
||||||
use crate::{
|
use crate::{
|
||||||
errors::VoiceGatewayError,
|
errors::VoiceGatewayError,
|
||||||
gateway::GatewayEvent,
|
|
||||||
types::{
|
types::{
|
||||||
VoiceGatewayReceivePayload, VoiceHelloData, WebSocketEvent, VOICE_BACKEND_VERSION,
|
VoiceGatewayReceivePayload, VoiceHelloData, WebSocketEvent, VOICE_BACKEND_VERSION,
|
||||||
VOICE_CLIENT_CONNECT_FLAGS, VOICE_CLIENT_CONNECT_PLATFORM, VOICE_CLIENT_DISCONNECT,
|
VOICE_CLIENT_CONNECT_FLAGS, VOICE_CLIENT_CONNECT_PLATFORM, VOICE_CLIENT_DISCONNECT,
|
||||||
|
|
|
@ -3,8 +3,9 @@
|
||||||
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||||
|
|
||||||
use discortp::{rtcp::Rtcp, rtp::Rtp};
|
use discortp::{rtcp::Rtcp, rtp::Rtp};
|
||||||
|
use pubserve::Publisher;
|
||||||
|
|
||||||
use crate::{gateway::GatewayEvent, types::WebSocketEvent};
|
use crate::types::WebSocketEvent;
|
||||||
|
|
||||||
impl WebSocketEvent for Rtp {}
|
impl WebSocketEvent for Rtp {}
|
||||||
impl WebSocketEvent for Rtcp {}
|
impl WebSocketEvent for Rtcp {}
|
||||||
|
@ -18,8 +19,8 @@ pub struct VoiceUDPEvents {
|
||||||
impl Default for VoiceUDPEvents {
|
impl Default for VoiceUDPEvents {
|
||||||
fn default() -> Self {
|
fn default() -> Self {
|
||||||
Self {
|
Self {
|
||||||
rtp: GatewayEvent::new(),
|
rtp: Publisher::new(),
|
||||||
rtcp: GatewayEvent::new(),
|
rtcp: Publisher::new(),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue