Fix 0 refresh rate used with Auto refresh rate
This commit is contained in:
@@ -112,4 +112,11 @@ struct wivrn_comp_target : public comp_target
|
||||
void set_refresh_rate(float);
|
||||
};
|
||||
|
||||
inline float get_default_rate(const from_headset::headset_info_packet & info, const from_headset::settings_changed & settings)
|
||||
{
|
||||
if (settings.preferred_refresh_rate)
|
||||
return settings.preferred_refresh_rate;
|
||||
return info.available_refresh_rates.back();
|
||||
}
|
||||
|
||||
} // namespace wivrn
|
||||
|
||||
Reference in New Issue
Block a user