Skip to content

Commit

Permalink
🏓 Ping handling for FTL media streams (#114)
Browse files Browse the repository at this point in the history
Pings are used by FTL clients to measure RTT as part of bandwidth estimation and congestion control.
  • Loading branch information
danstiner authored Mar 20, 2021
1 parent da56d95 commit 70799c0
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/FtlStream.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -587,11 +587,8 @@ void FtlStream::processAudioVideoRtpPacket(const std::vector<std::byte>& rtpPack

void FtlStream::handlePing(const std::vector<std::byte>& rtpPacket)
{
// These pings are useless - FTL tries to determine 'ping' by having a timestamp
// sent across and compared against the remote's clock. This assumes that there is
// no time difference between the client and server, which is practically never true.

// We'll just ignore these pings, since they wouldn't give us any useful information anyway.
// FTL client is trying to measure round trip time (RTT), pong back the same packet
mediaTransport->Write(rtpPacket);
}

void FtlStream::handleSenderReport(const std::vector<std::byte>& rtpPacket)
Expand Down

0 comments on commit 70799c0

Please sign in to comment.