mirror of
https://github.com/kunkundi/crossdesk.git
synced 2025-10-26 20:25:34 +08:00
[feat] move rtp packet sender out of channel module
This commit is contained in:
@@ -44,9 +44,9 @@ void AudioChannelSend::Destroy() {
|
||||
|
||||
int AudioChannelSend::SendAudio(char *data, size_t size) {
|
||||
if (rtp_audio_sender_ && rtp_packetizer_) {
|
||||
std::vector<std::shared_ptr<RtpPacket>> rtp_packets =
|
||||
std::vector<std::unique_ptr<RtpPacket>> rtp_packets =
|
||||
rtp_packetizer_->Build((uint8_t *)data, (uint32_t)size, 0, true);
|
||||
rtp_audio_sender_->Enqueue(rtp_packets);
|
||||
rtp_audio_sender_->Enqueue(std::move(rtp_packets));
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
||||
Reference in New Issue
Block a user