Skip to content

Commit

Permalink
Inverts XR_META_local_dimming to be ON by default.
Browse files Browse the repository at this point in the history
alxr-engine submodule update:
* Inverts XR_META_local_dimming to be ON by default.
  • Loading branch information
korejan committed Nov 6, 2022
1 parent a710ba7 commit e046d35
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion alvr/openxr-client/alxr-android-client/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ fn run(app_data: &mut AppData) -> Result<(), Box<dyn std::error::Error>> {
noSuggestedBindings: APP_CONFIG.no_bindings,
noServerFramerateLock: APP_CONFIG.no_server_framerate_lock,
noFrameSkip: APP_CONFIG.no_frameskip,
enableLocalDimming: APP_CONFIG.enable_localdimming,
disableLocalDimming: APP_CONFIG.disable_localdimming,
};
let mut sys_properties = ALXRSystemProperties::new();
if !alxr_init(&ctx, &mut sys_properties) {
Expand Down
2 changes: 1 addition & 1 deletion alvr/openxr-client/alxr-client/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ fn main() {
noSuggestedBindings: APP_CONFIG.no_bindings,
noServerFramerateLock: false,
noFrameSkip: false,
enableLocalDimming: APP_CONFIG.enable_localdimming,
disableLocalDimming: APP_CONFIG.disable_localdimming,
};
let mut sys_properties = ALXRSystemProperties::new();
if !alxr_init(&ctx, &mut sys_properties) {
Expand Down
14 changes: 7 additions & 7 deletions alvr/openxr-client/alxr-common/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ pub struct Options {
pub no_frameskip: bool,

#[structopt(/*short,*/ long)]
pub enable_localdimming: bool,
pub disable_localdimming: bool,
// /// Set speed
// // we don't want to name it "speed", need to look smart
// #[structopt(short = "v", long = "velocity", default_value = "42")]
Expand Down Expand Up @@ -108,7 +108,7 @@ impl Options {
no_bindings: false,
no_server_framerate_lock: false,
no_frameskip: false,
enable_localdimming: false,
disable_localdimming: false,
};

let sys_properties = AndroidSystemProperties::new();
Expand Down Expand Up @@ -162,13 +162,13 @@ impl Options {
);
}

let property_name = "debug.alxr.enable_localdimming";
let property_name = "debug.alxr.disable_localdimming";
if let Some(value) = sys_properties.get(&property_name) {
new_options.enable_localdimming = std::str::FromStr::from_str(value.as_str())
.unwrap_or(new_options.enable_localdimming);
new_options.disable_localdimming = std::str::FromStr::from_str(value.as_str())
.unwrap_or(new_options.disable_localdimming);
println!(
"ALXR System Property: {property_name}, input: {value}, parsed-result: {}",
new_options.enable_localdimming
new_options.disable_localdimming
);
}

Expand All @@ -190,7 +190,7 @@ impl Options {
no_bindings: false,
no_server_framerate_lock: false,
no_frameskip: false,
enable_localdimming: false,
disable_localdimming: false,
};
new_options
}
Expand Down

0 comments on commit e046d35

Please sign in to comment.