mirror of
https://github.com/moonlight-stream/moonlight-chrome.git
synced 2025-08-17 16:46:31 +00:00
Added frontend support for 4K
- This does NOT give full 4K support. The NaCl plugin still needs to support it - Progress commit on #42 - Fixed bad default value for 720p bitrate: from 15Mbps to 5Mbps
This commit is contained in:
parent
278824fea5
commit
97fc2d4fa8
@ -29,6 +29,7 @@
|
|||||||
<select id="selectResolution">
|
<select id="selectResolution">
|
||||||
<option value="1280:720">1280x720</option>
|
<option value="1280:720">1280x720</option>
|
||||||
<option value="1920:1080">1920x1080</option>
|
<option value="1920:1080">1920x1080</option>
|
||||||
|
<option value="2160:3840">2160x3840</option>
|
||||||
</select>
|
</select>
|
||||||
</div>
|
</div>
|
||||||
<div class="mdl-select">
|
<div class="mdl-select">
|
||||||
@ -36,9 +37,9 @@
|
|||||||
<option value="30">30fps</option>
|
<option value="30">30fps</option>
|
||||||
<option value="60">60fps</option>
|
<option value="60">60fps</option>
|
||||||
</select>
|
</select>
|
||||||
<output id='bitrateField'>15 Mbps</output>
|
<output id='bitrateField'>5 Mbps</output>
|
||||||
</div>
|
</div>
|
||||||
<input id="bitrateSlider" class="mdl-slider mdl-js-slider" type="range" min="0" max="100" step="0.5" value="15">
|
<input id="bitrateSlider" class="mdl-slider mdl-js-slider" type="range" min="0" max="100" step="0.5" value="5">
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="hostSettings">
|
<div id="hostSettings">
|
||||||
|
@ -428,7 +428,14 @@ function updateDefaultBitrate() {
|
|||||||
} else { // 720, 60fps
|
} else { // 720, 60fps
|
||||||
$('#bitrateSlider')[0].MaterialSlider.change('10');
|
$('#bitrateSlider')[0].MaterialSlider.change('10');
|
||||||
}
|
}
|
||||||
|
} else if (res.lastIndexOf("2160:3840", 0) === 0) {
|
||||||
|
if (frameRate.lastIndexOf("30", 0) === 0) { // 2160p, 30fps
|
||||||
|
$('#bitrateSlider')[0].MaterialSlider.change('40');
|
||||||
|
} else { // 2160p, 60fps
|
||||||
|
$('#bitrateSlider')[0].MaterialSlider.change('80');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
updateBitrateField();
|
updateBitrateField();
|
||||||
saveBitrate();
|
saveBitrate();
|
||||||
}
|
}
|
||||||
@ -459,7 +466,7 @@ function onWindowLoad(){
|
|||||||
});
|
});
|
||||||
// load stored bitrate prefs
|
// load stored bitrate prefs
|
||||||
chrome.storage.sync.get('bitrate', function(previousValue) {
|
chrome.storage.sync.get('bitrate', function(previousValue) {
|
||||||
$('#bitrateSlider')[0].MaterialSlider.change(previousValue.bitrate != null ? previousValue.bitrate : '15');
|
$('#bitrateSlider')[0].MaterialSlider.change(previousValue.bitrate != null ? previousValue.bitrate : '5');
|
||||||
updateBitrateField();
|
updateBitrateField();
|
||||||
});
|
});
|
||||||
// load the HTTP cert if we have one.
|
// load the HTTP cert if we have one.
|
||||||
@ -489,4 +496,3 @@ function onWindowLoad(){
|
|||||||
|
|
||||||
|
|
||||||
window.onload = onWindowLoad;
|
window.onload = onWindowLoad;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user