Prefer FB passthrough over base OpenXR one

This commit is contained in:
Patrick Nicolas
2025-04-07 17:15:40 +02:00
parent b1a73f7352
commit 2f195857e7
+5 -5
View File
@@ -383,11 +383,7 @@ void xr::session::enable_passthrough(xr::system & system)
if (system.passthrough_supported() == xr::system::passthrough_type::no_passthrough)
return;
if (utils::contains(system.environment_blend_modes(XR_VIEW_CONFIGURATION_TYPE_PRIMARY_STEREO), XR_ENVIRONMENT_BLEND_MODE_ALPHA_BLEND))
{
passthrough.emplace<xr::passthrough_alpha_blend>();
}
else if (utils::contains(application::get_xr_extensions(), XR_FB_PASSTHROUGH_EXTENSION_NAME))
if (utils::contains(application::get_xr_extensions(), XR_FB_PASSTHROUGH_EXTENSION_NAME))
{
passthrough.emplace<xr::passthrough_fb>(*inst, *this);
}
@@ -395,6 +391,10 @@ void xr::session::enable_passthrough(xr::system & system)
{
passthrough.emplace<xr::passthrough_htc>(*inst, *this);
}
else if (utils::contains(system.environment_blend_modes(XR_VIEW_CONFIGURATION_TYPE_PRIMARY_STEREO), XR_ENVIRONMENT_BLEND_MODE_ALPHA_BLEND))
{
passthrough.emplace<xr::passthrough_alpha_blend>();
}
}
void xr::session::disable_passthrough()