mirror of
https://github.com/yuzu-emu/yuzu.git
synced 2024-07-04 23:31:19 +01:00
Merge pull request #2894 from wwylele/motion-emu-fix
motion_emu: fix initialization order
This commit is contained in:
commit
03c782e378
1 changed files with 4 additions and 1 deletions
|
@ -74,11 +74,14 @@ private:
|
||||||
bool is_tilting = false;
|
bool is_tilting = false;
|
||||||
|
|
||||||
Common::Event shutdown_event;
|
Common::Event shutdown_event;
|
||||||
std::thread motion_emu_thread;
|
|
||||||
|
|
||||||
std::tuple<Math::Vec3<float>, Math::Vec3<float>> status;
|
std::tuple<Math::Vec3<float>, Math::Vec3<float>> status;
|
||||||
std::mutex status_mutex;
|
std::mutex status_mutex;
|
||||||
|
|
||||||
|
// Note: always keep the thread declaration at the end so that other objects are initialized
|
||||||
|
// before this!
|
||||||
|
std::thread motion_emu_thread;
|
||||||
|
|
||||||
void MotionEmuThread() {
|
void MotionEmuThread() {
|
||||||
auto update_time = std::chrono::steady_clock::now();
|
auto update_time = std::chrono::steady_clock::now();
|
||||||
Math::Quaternion<float> q = MakeQuaternion(Math::Vec3<float>(), 0);
|
Math::Quaternion<float> q = MakeQuaternion(Math::Vec3<float>(), 0);
|
||||||
|
|
Loading…
Reference in a new issue