Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
60 commits
Select commit Hold shift + click to select a range
1b0a367
Do not switch to statistics tab after connection
zmerp Jul 4, 2022
ac51254
Expose nvenc and mediacodec options
zmerp Sep 23, 2022
1a868b0
update sdk
Vixea Oct 9, 2022
b7f8af5
Introduce AMF Pre-Processor, 10-bit support and configurable encoder …
deiteris Oct 26, 2022
0e3b8a6
Split AMF pipeline and video transmission to different threads
deiteris Nov 2, 2022
0037ae5
Add sleep to threads
deiteris Nov 2, 2022
ce76c0d
Disallow 10-bit with H.264
deiteris Nov 2, 2022
bc952e5
Remove unnecessary debugging
deiteris Nov 2, 2022
aa8c889
Refactor VideoEncoderVCE settings
deiteris Nov 2, 2022
c37844d
Use component names in debug messages
deiteris Nov 2, 2022
60822eb
Turn off IDR/I Frames
Vixea Nov 3, 2022
936f82a
fix compile error
Vixea Nov 3, 2022
64b68b6
fixes for x265
Vixea Nov 3, 2022
3d7d549
Set VBV buffer size to max frame size
deiteris Nov 3, 2022
10b34cd
Use infinite GOP length for AMF HEVC
deiteris Nov 3, 2022
eafba74
Use digits delimiter for bitrate number
deiteris Nov 7, 2022
c108d92
Remove AUD in encoder component and add manual check for h264
deiteris Nov 7, 2022
020d913
remove setting MAX_QP and the hevc versions
Vixea Nov 10, 2022
6c42795
Enable CBR in AMF
deiteris Nov 15, 2022
8153561
Terminate AMF context and factory on shutdown
deiteris Nov 16, 2022
59b9031
Set profile properties before picture properties
deiteris Nov 16, 2022
de66163
AMF changes (#1281)
deiteris Nov 28, 2022
a43e542
Configurable rate control mode (#1287)
deiteris Dec 2, 2022
5d3587c
change MAX_NUM_REFRAMES
Vixea Dec 12, 2022
e6507cd
Remove separate AMF pipeline thread (#1302)
deiteris Dec 12, 2022
3f0679d
Entropy coding option (#1318)
deiteris Dec 24, 2022
b9a6cae
Update Video Codec SDK (#1331)
deiteris Dec 28, 2022
79fcd0b
Add VBAQ option (#1336)
deiteris Jan 4, 2023
214bb37
Minor AMF fixes for Windows (#1367)
deiteris Jan 23, 2023
439d43a
Windows: use 1.1 frame VBV buffer size for all encoders (#1397)
deiteris Jan 23, 2023
a2b3a88
Windows: Include filler data in nvenc
deiteris Feb 21, 2023
22fd669
Use option instead of const for filler data (#1533)
deiteris Mar 26, 2023
2d6da3b
Recompile server d3d shaders
korejan May 21, 2023
b333860
Fix json parse error message
korejan Jun 10, 2023
0b03bbc
Fix UE5 crash with custom depth texture (#1685)
deiteris Jun 16, 2023
788445d
better defaults
korejan Jun 26, 2023
c3bc458
fix linux builds
korejan Jul 3, 2023
f9604c5
AMF sdk v1.4.30
korejan Aug 19, 2023
69ffc65
nvenc sdk v12.1
korejan Aug 19, 2023
b091041
OpenVR SDK 1.26.7
korejan Aug 20, 2023
3d782f4
assortment of optimizations
korejan Aug 20, 2023
f0c666a
OpenVR SDK 2.0.10
korejan Nov 8, 2023
7a26f1e
output .pdbs in win build dir
korejan Dec 19, 2023
68d6b91
small optimizations
korejan Dec 19, 2023
e5058b6
Reuse frame buffer allocations for nvenc
korejan Dec 19, 2023
ed2a391
Reduce redundant copies/allocs for frame packet sends
korejan Dec 19, 2023
d65fc1a
Changes resolution rounding + default settings tweaks
korejan Feb 11, 2024
c968669
OpenVR SDK 2.2.3
korejan Feb 11, 2024
660b62d
input update opt
korejan Feb 24, 2024
1edd5e4
fix build with missing pdbs files.
korejan Mar 23, 2024
dd09796
OpenVR SDK 2.5.1
korejan Apr 6, 2024
0ef772b
re-enable pdb for driver
korejan May 13, 2024
8fd59d5
nvenc sdk v12.2.72
korejan Jun 9, 2024
69e7add
amf sdk v1.4.33
korejan Jun 9, 2024
5601929
fix zero sample count
korejan Aug 26, 2024
3858602
workaround-fix jittery system overlays during low framerates
korejan Feb 6, 2025
60a8e22
Adds support for color quantization scheme option
korejan Mar 9, 2025
a149370
make microphone on by default
korejan Oct 23, 2025
6f3d9e7
nvenc sdk 13.0.19
korejan Oct 29, 2025
ab24f91
amf sdk v1.5.0
korejan Oct 31, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions alvr/dashboard/js/app/customSettings.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ define([
) {
return function (alvrSettings) {
const self = this;
const video_scales = [25, 50, 66, 75, 100, 125, 150, 200];
const video_scales = [25, 50, 66, 75, 100, 125, 140, 150, 200];

self.setCustomSettings = function () {
try {
Expand Down Expand Up @@ -588,10 +588,10 @@ define([
${alvrSettings.getHelpReset(
"trackingSpeed",
"_root_headset_controllers_content",
"steamvr",
"oculus",
(postFix = ""),
"trackingSpeed",
i18nWizard.steamvrTracking
i18nWizard.oculusTracking
)}
</div>
<div class="btn-group" data-toggle="buttons" id="trackingSpeedButtons">
Expand Down
36 changes: 0 additions & 36 deletions alvr/dashboard/js/app/monitor.js
Original file line number Diff line number Diff line change
Expand Up @@ -892,42 +892,6 @@ define([
}

function updateStatistics(statistics) {
clearTimeout(timeoutHandler);
// $("#connectionCard").hide();
// $("#statisticsCard").show();
if (!clientConnected) {
clientConnected = true;
// hide connection
if ($("#connectionTab").hasClass("active"))
$("#connectionTab").removeClass("active");
if ($("#connection").hasClass("active")) $("#connection").removeClass("active");
// show statistics
if (!$("#statisticsTab").hasClass("active")) $("#statisticsTab").addClass("active");
if (!$("#statistics").hasClass("active")) $("#statistics").addClass("active");
if (!$("#statistics").hasClass("show")) $("#statistics").addClass("show");
// hide logging
if ($("#loggingTab").hasClass("active")) $("#loggingTab").removeClass("active");
if ($("#logging").hasClass("active")) $("#logging").removeClass("active");
if ($("#logging").hasClass("show")) $("#logging").removeClass("show");
}
timeoutHandler = setTimeout(() => {
// $("#connectionCard").show();
// $("#statisticsCard").hide();
clientConnected = false;
// show connection
if (!$("#connectionTab").hasClass("active")) $("#connectionTab").addClass("active");
if (!$("#connection").hasClass("active")) $("#connection").addClass("active");
// hide statistics
if ($("#statisticsTab").hasClass("active"))
$("#statisticsTab").removeClass("active");
if ($("#statistics").hasClass("active")) $("#statistics").removeClass("active");
if ($("#statistics").hasClass("show")) $("#statistics").removeClass("show");
// hide logging
if ($("#loggingTab").hasClass("active")) $("#loggingTab").removeClass("active");
if ($("#logging").hasClass("active")) $("#logging").removeClass("active");
if ($("#logging").hasClass("show")) $("#logging").removeClass("show");
}, 2000);

for (const stat in statistics) {
$("#statistic_" + stat).text(statistics[stat]);
}
Expand Down
37 changes: 36 additions & 1 deletion alvr/dashboard/js/app/nls/settings.js
Original file line number Diff line number Diff line change
Expand Up @@ -68,12 +68,47 @@ define({
"HEVC is preferred to achieve better visual quality on lower bitrates. AMD video cards work best with HEVC.",
"_root_video_codec_H264-choice-.name": "h264",
"_root_video_codec_HEVC-choice-.name": "HEVC (h265)",
"_root_video_colorRange-choice-.name": "Color Range",
"_root_video_colorRange-choice-.description":
"Controls how colors are processed when converting between different color systems. Full Range uses all available colors for richer, more detailed images, while Limited Range adjusts the colors to match common video standards.",
"_root_video_clientRequestRealtimeDecoder.name":
"Request realtime decoder priority (client)", // adv
"_root_video_use10bitEncoder.name":
"Reduce color banding (newer nVidia cards or SW encoding only)",
"_root_video_use10bitEncoder.description":
"This increases visual quality by streaming 10 bit per color channel instead of 8",
"This increases visual quality by streaming 10 bits per color channel instead of 8. Works on all supported platforms except nvidia on linux.",
"_root_video_rateControlMode-choice-.name":
"Rate control mode",
"_root_video_rateControlMode-choice-.description":
"Specifies the bitrate control method (Windows with AMD and nVidia cards only). CBR - constant bitrate, VBR - variable bitrate.",
"_root_video_rateControlMode_cbr-choice-.name": "CBR",
"_root_video_rateControlMode_vbr-choice-.name": "VBR",
"_root_video_entropyCoding-choice-.name": "Entropy coding method",
"_root_video_entropyCoding-choice-.description":
"Specifies the entropy coding method (h264 only). CABAC - provides better quality at lower bitrate, but may increase the encoder/decoder latency, CAVLC - provides worse quality that can be compensated with higher bitrate, and may significantly decrease encoder/decoder latency.",
"_root_video_entropyCoding_cabac-choice-.name": "CABAC",
"_root_video_entropyCoding_cavlc-choice-.name": "CAVLC",
"_root_video_advancedCodecOptions_amfControls_enableVbaq.name":
"Enable VBAQ",
"_root_video_advancedCodecOptions_amfControls_enableVbaq.description":
"Enables Variance Based Adaptive Quantization (VBAQ) that allocates more bits to smooth areas (gradients, solid colors), but picture details may suffer from compression artifacts.",
"_root_video_advancedCodecOptions_amfControls_usePreproc.name":
"Enable Pre-Processor component",
"_root_video_advancedCodecOptions_amfControls_usePreproc.description":
"Enables Pre-Processor component (RX 5000+ models with 8-bit encoding only). Removing bit-expensive high frequency details that are deemed not important for the human visual system.",
"_root_video_advancedCodecOptions_amfControls_preprocSigma.name": "Pre-Processor strength",
"_root_video_advancedCodecOptions_amfControls_preprocSigma.description":
"Strength of the pre-processing filter. The higher the strength, the stronger the filtering.",
"_root_video_advancedCodecOptions_amfControls_preprocTor.name": "Pre-Processor sensitivity",
"_root_video_advancedCodecOptions_amfControls_preprocTor.description":
"Sensitivity to edges. The higher the value, the more likely edges will be detected, and hence the less likely filtering will occur.",
"_root_video_advancedCodecOptions_amfControls_encoderQualityPreset.name":
"Encoder quality preset",
"_root_video_advancedCodecOptions_amfControls_encoderQualityPreset.description":
"Controls the encoder quality.",
"_root_video_forceSwEncoding.name": "Force Software Encoding",
"_root_video_forceSwEncoding.description":
"This forces the Encoder to use CPU(Software Encoding) instead of GPU(Hardware Encoding).",
"_root_video_swThreadCount.name": "Number of threads (software encoding)",
"_root_video_swThreadCount.description":
"Sets the amount of threads to use when using software encoding. Setting to 0 will use the max amount available.",
Expand Down
31 changes: 23 additions & 8 deletions alvr/dashboard/js/app/setupWizard.js
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,18 @@ define([
keyboard: false,
});

var trackingRadioButton = $("input:radio[name='tracking'][value='oculus']");
if (trackingRadioButton.length > 0) {
trackingRadioButton.prop("checked", "true");
trackingRadioButton.parent().addClass("active");
}

var perfRadioButton = $("input:radio[name='performance'][value='visual_quality']");
if (perfRadioButton.length > 0) {
perfRadioButton.prop("checked", "true");
perfRadioButton.parent().addClass("active");
}

$("#wizardBackButton").hide();

$("#GPUSupportText").text(getAndCheckGPUSupport());
Expand Down Expand Up @@ -169,15 +181,17 @@ define([
const ffrStrengthTarget = $("#_root_video_foveatedRendering_content_strength");
const bitrateTarget = $("#_root_video_encodeBitrateMbs");
const preferredFps = $("#_root_video_preferredFps");
const adaptiveBitrate = $("#_root_connection_adaptiveBitrateEnabled");

switch (target.attr("value")) {
case "compatibility":
renderResolutionScale.val(0.75);
targetResolutionScale.val(0.75);
bitrateTarget.val(15);
renderResolutionScale.val(1.25);
targetResolutionScale.val(1.25);
bitrateTarget.val(60);
enableFfrTarget.prop("checked", true);
adaptiveBitrate.prop("checked", true);
ffrStrengthTarget.val(2);
preferredFps.val(72);
preferredFps.val(90);

const h264CodecTarget = $("#_root_video_codec_H264-choice-");
h264CodecTarget
Expand All @@ -190,10 +204,11 @@ define([
alvrSettings.storeParam(h264CodecTarget);
break;
case "visual_quality":
renderResolutionScale.val(1);
targetResolutionScale.val(1);
bitrateTarget.val(40);
enableFfrTarget.prop("checked", false);
renderResolutionScale.val(1.4);
targetResolutionScale.val(1.4);
bitrateTarget.val(150);
adaptiveBitrate.prop("checked", false);
enableFfrTarget.prop("checked", true);
preferredFps.val(90);

const hevcCodecTarget = $("#_root_video_codec_HEVC-choice-");
Expand Down
4 changes: 2 additions & 2 deletions alvr/dashboard/js/app/templates/wizard.html
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ <h6><%= titleTracking %></h6>
<div class="wizzardSettings">
<div class="btn-group" data-toggle="buttons">
<label class="btn btn-primary">
<input type="radio" name="tracking" class="poseOffsetButton" autocomplete="off" value="oculus">
<input type="radio" name="tracking" class="poseOffsetButton" autocomplete="off" value="oculus" checked>
<%= oculusTracking %>
</label>
<label class="btn btn-primary">
Expand Down Expand Up @@ -80,7 +80,7 @@ <h6><%= titlePerformance %></h6>
</label>
<label class="btn btn-primary">
<input type="radio" name="performance" class="performanceOptions" autocomplete="off"
value="visual_quality">
value="visual_quality" checked>
<%= qualityPerformance %>
</label>
</div>
Expand Down
9 changes: 9 additions & 0 deletions alvr/filesystem/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,10 @@ impl Layout {
self.executables_dir.join(exe)
}

pub fn launcher_pdb(&self) -> PathBuf {
self.executables_dir.join("alvr_launcher.pdb")
}

pub fn resources_dir(&self) -> PathBuf {
self.openvr_driver_root_dir.join("resources")
}
Expand Down Expand Up @@ -267,6 +271,11 @@ impl Layout {
.join(format!("driver_alvr_server.{ext}"))
}

pub fn openvr_driver_pdb(&self) -> PathBuf {
self.openvr_driver_lib_dir()
.join(format!("driver_alvr_server.pdb"))
}

// path to the manifest file for openVR
pub fn openvr_driver_manifest(&self) -> PathBuf {
self.openvr_driver_root_dir.join("driver.vrdrivermanifest")
Expand Down
11 changes: 8 additions & 3 deletions alvr/server/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ use std::{env, path::PathBuf};
#[cfg(target_os = "linux")]
fn do_ffmpeg_pkg_config(build: &mut cc::Build) {
let ffmpeg_path =
env::var("CARGO_MANIFEST_DIR").unwrap() + "/../../deps/linux/FFmpeg-release-5.1";
env::var("CARGO_MANIFEST_DIR").unwrap() + "/../../deps/linux/FFmpeg-release-5.1/";

#[cfg(feature = "bundled_ffmpeg")]
{
Expand Down Expand Up @@ -108,17 +108,22 @@ fn main() {
let mut build = cc::Build::new();
build
.cpp(true)
.std("c++20")
.files(source_files_paths)
.flag_if_supported("-isystemcpp/openvr/headers") // silences many warnings from openvr headers
.flag_if_supported("-std=c++17")
.flag_if_supported("-std=c++20")
.include("cpp/openvr/headers")
.include("cpp");

#[cfg(windows)]
build
.debug(false) // This is because we cannot link to msvcrtd (see below)
.flag("/std:c++17")
.flag("/std:c++20")
.flag("/permissive-")
.flag_if_supported("/Oi")
.flag_if_supported("/Ob2")
.flag_if_supported("/fp:contract")
//.flag_if_supported("/GL")
.define("NOMINMAX", None)
.define("_WINSOCKAPI_", None)
.define("_MBCS", None)
Expand Down
16 changes: 14 additions & 2 deletions alvr/server/cpp/ALVR-common/packet_types.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,20 @@ enum ALVR_CODEC {
ALVR_CODEC_H265 = 1,
};

enum ALVR_LOST_FRAME_TYPE {
ALVR_LOST_FRAME_TYPE_VIDEO = 0,
enum ALVR_RATE_CONTROL_METHOD {
ALVR_CBR = 0,
ALVR_VBR = 1,
};

enum ALVR_ENTROPY_CODING {
ALVR_CABAC = 0,
ALVR_CAVLC = 1,
};

enum ALVR_ENCODER_QUALITY_PRESET {
ALVR_QUALITY = 0,
ALVR_BALANCED = 1,
ALVR_SPEED = 2
};

enum ALVR_INPUT {
Expand Down
52 changes: 26 additions & 26 deletions alvr/server/cpp/ALVR-common/reedsolomon/rs.c
Original file line number Diff line number Diff line change
Expand Up @@ -320,9 +320,17 @@ static int invert_mat(gf *src, int k) {
}
for (col = k-1 ; col >= 0 ; col-- ) {
if (indxr[col] <0 || indxr[col] >= k)
#ifdef NDEBUG
continue;
#else
fprintf(stderr, "AARGH, indxr[col] %d\n", indxr[col]);
#endif
else if (indxc[col] <0 || indxc[col] >= k)
#ifdef NDEBUG
continue;
#else
fprintf(stderr, "AARGH, indxc[col] %d\n", indxc[col]);
#endif
else
if (indxr[col] != indxc[col] ) {
for (row = 0 ; row < k ; row++ )
Expand Down Expand Up @@ -375,16 +383,14 @@ void reed_solomon_init(void) {
init_mul_table();
}

reed_solomon* reed_solomon_new(int data_shards, int parity_shards) {
int reed_solomon_new(int data_shards, int parity_shards, reed_solomon* rs) {
gf* vm = NULL;
gf* top = NULL;
int err = 0;
reed_solomon* rs = NULL;

do {
rs = (reed_solomon *)malloc(sizeof(reed_solomon));
if (NULL == rs)
return NULL;
return -1;

rs->data_shards = data_shards;
rs->parity_shards = parity_shards;
Expand Down Expand Up @@ -440,39 +446,33 @@ reed_solomon* reed_solomon_new(int data_shards, int parity_shards) {
free(top);
vm = NULL;
top = NULL;
return rs;
return 0;

} while(0);

fprintf(stderr, "err=%d\n", err);
if (err != 0) {
fprintf(stderr, "err=%d\n", err);
}

if (NULL != vm)
free(vm);

if (NULL != top)
free(top);

if (NULL != rs) {
if (NULL != rs->m)
free(rs->m);

if (NULL != rs->parity)
free(rs->parity);

free(rs);
}

return NULL;
reed_solomon_release(rs);
return -1;
}

void reed_solomon_release(reed_solomon* rs) {
if (NULL != rs) {
if (NULL != rs->m)
free(rs->m);

if (NULL != rs->parity)
free(rs->parity);

free(rs);
if (NULL == rs)
return ;
if (NULL != rs->m) {
free(rs->m);
rs->m = NULL;
}
if (NULL != rs->parity) {
free(rs->parity);
rs->parity = NULL;
}
}

Expand Down
2 changes: 1 addition & 1 deletion alvr/server/cpp/ALVR-common/reedsolomon/rs.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ extern "C" {
* */
void reed_solomon_init(void);

reed_solomon* reed_solomon_new(int data_shards, int parity_shards);
int reed_solomon_new(int data_shards, int parity_shards, reed_solomon* rs_out);
void reed_solomon_release(reed_solomon* rs);

/**
Expand Down
Loading
Loading