From 8e9d6052487aec67c631805047ebd2ac80e722de Mon Sep 17 00:00:00 2001 From: Cameron Gutman Date: Mon, 12 May 2014 20:00:52 -0500 Subject: [PATCH] Clamp to min = max so we can eliminate the time taken to scale the bitrate up to the ceiling --- .../com/limelight/nvstream/rtsp/SdpGenerator.java | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/moonlight-common/src/com/limelight/nvstream/rtsp/SdpGenerator.java b/moonlight-common/src/com/limelight/nvstream/rtsp/SdpGenerator.java index 3d2f3da0..5253f95e 100644 --- a/moonlight-common/src/com/limelight/nvstream/rtsp/SdpGenerator.java +++ b/moonlight-common/src/com/limelight/nvstream/rtsp/SdpGenerator.java @@ -159,15 +159,9 @@ public class SdpGenerator { addSessionAttribute(config, "x-nv-vqos[0].ts.maximumBitrate", "10"); addSessionAttribute(config, "x-nv-vqos[0].bw.flags", "819"); // Bit 2 being set causes picture problems (should be 823) - // Effective bitrate ceiling - if (sc.getHeight() >= 1080 && sc.getRefreshRate() >= 60) { - addSessionAttribute(config, "x-nv-vqos[0].bw.maximumBitrate", ""+sc.getBitrate()); - addSessionAttribute(config, "x-nv-vqos[0].bw.minimumBitrate", "20000"); - } - else { - addSessionAttribute(config, "x-nv-vqos[0].bw.maximumBitrate", ""+sc.getBitrate()); - addSessionAttribute(config, "x-nv-vqos[0].bw.minimumBitrate", "2000"); - } + // We clamp to min = max so manual bitrate settings take effect without time to scale up + addSessionAttribute(config, "x-nv-vqos[0].bw.maximumBitrate", ""+sc.getBitrate()); + addSessionAttribute(config, "x-nv-vqos[0].bw.minimumBitrate", ""+sc.getBitrate()); addSessionAttribute(config, "x-nv-vqos[0].bw.statsTime", "50"); addSessionAttribute(config, "x-nv-vqos[0].bw.zeroLossCount", "3000");