Merge branch 'sync' into sneed
This commit is contained in:
@@ -40,6 +40,7 @@
|
||||
#include "wivrn_packets.h"
|
||||
#include "xr/to_string.h"
|
||||
|
||||
#include "b_hand_tracker.h"
|
||||
#include "b_system.h"
|
||||
#include "target_builder_helpers.h"
|
||||
#include "util/u_logging.h"
|
||||
@@ -78,6 +79,7 @@ bool is_forced_extension(const char * ext_name)
|
||||
wivrn::wivrn_session::wivrn_session(std::unique_ptr<wivrn_connection> connection, b_system & system) :
|
||||
xrt_system_devices{
|
||||
.get_roles = method_pointer<&wivrn_session::get_roles>,
|
||||
.create_hand_tracker = b_hand_tracker_create,
|
||||
.feature_inc = method_pointer<&wivrn_session::feature_inc>,
|
||||
.feature_dec = method_pointer<&wivrn_session::feature_dec>,
|
||||
.destroy = method_pointer<&wivrn_session::destroy>,
|
||||
@@ -401,11 +403,15 @@ void wivrn_session::resume_session()
|
||||
|
||||
if (target_fps != current_fps)
|
||||
{
|
||||
auto s = settings.lock();
|
||||
(*this)(from_headset::refresh_rate_changed{
|
||||
.from = current_fps * s->fps_divider,
|
||||
.to = target_fps * s->fps_divider,
|
||||
});
|
||||
compositor.set_framerate(target_fps);
|
||||
push_event(
|
||||
{
|
||||
.display = {
|
||||
.type = XRT_SESSION_EVENT_DISPLAY_REFRESH_RATE_CHANGE,
|
||||
.from_display_refresh_rate_hz = current_fps,
|
||||
.to_display_refresh_rate_hz = target_fps,
|
||||
},
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user