Skip to content

Commit

Permalink
Correct typo in sample code
Browse files Browse the repository at this point in the history
  • Loading branch information
chun137 committed Sep 25, 2024
1 parent e9d88a9 commit 7e39768
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions explainer.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@ This specification adds captureTimestamp, type of DOMHighResTimeStamp, to the RT

[receiverAudio, receiverVideo] = peerconnection.getReceivers();

latestCaptureTimestampAudio = receiverAudio.getSynchronizationSources()[0].captureTimeStamp;
latestCaptureTimestampVideo = receiverVideo.getSynchronizationSources()[0].captureTimeStamp;
latestCaptureTimestampAudio = receiverAudio.getSynchronizationSources()[0].captureTimestamp;
latestCaptureTimestampVideo = receiverVideo.getSynchronizationSources()[0].captureTimestamp;

synchronizationError = latestCaptureTimestampAudio - latestCaptureTimestampVideo;

Expand All @@ -63,8 +63,8 @@ An example code to use captureTimestamp and senderCaptureTimeOffset to calculate

receiver = peerconnection.getReceivers()[0];
csrc = receiver.getSynchronizationSources()[0];
latestCaptureTimestamp = csrc.captureTimeStamp;
latestSenderCaptureTimeOffset = csrc.SenderCaptureTimeOffset;
latestCaptureTimestamp = csrc.captureTimestamp;
latestSenderCaptureTimeOffset = csrc.senderCaptureTimeOffset;
receiverTimestamp = csrc.timestamp;

// Calculates sender-receiver clock offset from stats.
Expand All @@ -77,7 +77,7 @@ An example code to use captureTimestamp and senderCaptureTimeOffset to calculate
captureReceiverTimeOffset = senderReceiverTimeOffset + latestSenderCaptureTimeOffset;

receiverCaptureTimestamp = latestCaptureTimestamp + captureReceiverTimeOffset;
endToEndDelay = receiverTimestamp - receiverCaptureTimestamp.
endToEndDelay = receiverTimestamp - receiverCaptureTimestamp;

#### Detailed design discussion

Expand Down

0 comments on commit 7e39768

Please sign in to comment.