Skip to content
Snippets Groups Projects
Commit f7c94fc8 authored by George Politis's avatar George Politis
Browse files

Minor non-functional changes.

parent 2d40cd4f
No related branches found
No related tags found
No related merge requests found
......@@ -30,7 +30,7 @@ public class BasicRTCPTerminationStrategy
* The cache processor that will be making the RTCP reports coming from
* the bridge.
*/
private FeedbackCacheProcessor feedbackCacheProcessor;
private final FeedbackCacheProcessor feedbackCacheProcessor;
/**
* A cache of media receiver feedback. It contains both receiver report
......@@ -44,6 +44,11 @@ public class BasicRTCPTerminationStrategy
public BasicRTCPTerminationStrategy()
{
this.feedbackCache = new FeedbackCache();
this.feedbackCacheProcessor
= new FeedbackCacheProcessor(feedbackCache);
// TODO(gp) make percentile configurable.
this.feedbackCacheProcessor.setPercentile(70);
setTransformerChain(new Transformer[]{
new FeedbackCacheUpdater(feedbackCache),
......@@ -104,15 +109,8 @@ public RTCPPacket[] makeReports()
// Include REMB.
// TODO(gp) build REMB packets from scratch, like we do in the bridge.
if (this.feedbackCacheProcessor == null)
{
this.feedbackCacheProcessor
= new FeedbackCacheProcessor(feedbackCache);
// TODO(gp) make percentile configurable.
this.feedbackCacheProcessor.setPercentile(70);
}
// TODO(gp) build REMB packets from scratch instead of relying on the
// feedback cache processor, just like we do in the JVB.
RTCPPacket[] bestReceiverFeedback = feedbackCacheProcessor.makeReports(
localSSRC);
......
......@@ -120,7 +120,7 @@ public class HighestQualityRTCPTerminationStrategy
* The cache processor that will be making the RTCP reports coming from
* the bridge.
*/
private FeedbackCacheProcessor feedbackCacheProcessor;
private final FeedbackCacheProcessor feedbackCacheProcessor;
/**
* A cache of media receiver feedback. It contains both receiver report
......@@ -134,6 +134,11 @@ public class HighestQualityRTCPTerminationStrategy
public HighestQualityRTCPTerminationStrategy()
{
this.feedbackCache = new FeedbackCache();
this.feedbackCacheProcessor
= new FeedbackCacheProcessor(feedbackCache);
// TODO(gp) make percentile configurable.
this.feedbackCacheProcessor.setPercentile(70);
setTransformerChain(new Transformer[]{
new FeedbackCacheUpdater(feedbackCache),
......@@ -152,15 +157,6 @@ public RTCPPacket[] makeReports()
long localSSRC = ((RTPTranslatorImpl)t).getLocalSSRC(null);
if (this.feedbackCacheProcessor == null)
{
this.feedbackCacheProcessor
= new FeedbackCacheProcessor(feedbackCache);
// TODO(gp) make percentile configurable.
this.feedbackCacheProcessor.setPercentile(70);
}
RTCPPacket[] packets = feedbackCacheProcessor.makeReports(
(int) localSSRC);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment