1. Liam Staskawicz
  2. go-rtp

Commits

Liam Staskawicz  committed e49324a

source: standardize const names

  • Participants
  • Parent commits 005194b
  • Branches master

Comments (0)

Files changed (1)

File rtp/source.go

View file
 	"sync"
 )
 
-const rtpSeqMod = 1 << 16
-
 const (
-	MAX_DROPOUT    = 3000
-	MAX_MISORDER   = 100
-	MIN_SEQUENTIAL = 2
+	rtpSeqMod     = 1 << 16
+	maxDropout    = 3000
+	maxMisorder   = 100
+	minSequential = 2
 )
 
 type memberTable struct {
 	}
 	s.initSeq(h.SeqNum)
 	s.maxSeq = h.SeqNum - 1
-	s.probation = MIN_SEQUENTIAL
+	s.probation = minSequential
 
 	t.m[s.ssrc] = s
 	return s
 				return true
 			}
 		} else {
-			s.probation = MIN_SEQUENTIAL - 1
+			s.probation = minSequential - 1
 			s.maxSeq = seq
 		}
 		return false
 	}
 
-	if udelta < MAX_DROPOUT {
+	if udelta < maxDropout {
 		// in order, with permissible gap
 		if seq < s.maxSeq {
 			// Sequence number wrapped - count another 64K cycle.
 		}
 		s.maxSeq = seq
 
-	} else if udelta <= rtpSeqMod-MAX_MISORDER {
+	} else if udelta <= rtpSeqMod-maxMisorder {
 		// the sequence number made a very large jump
 		if uint32(seq) == s.badSeq {
 			// Two sequential packets -- assume that the other side