You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-29 16:16:38 +00:00
Added gyroscope support to Godot and Android
This commit is contained in:
@@ -259,6 +259,12 @@ Vector3 InputDefault::get_magnetometer() {
|
||||
return magnetometer;
|
||||
}
|
||||
|
||||
Vector3 InputDefault::get_gyroscope() {
|
||||
|
||||
_THREAD_SAFE_METHOD_
|
||||
return gyroscope;
|
||||
}
|
||||
|
||||
void InputDefault::parse_input_event(const InputEvent& p_event) {
|
||||
|
||||
_THREAD_SAFE_METHOD_
|
||||
@@ -386,6 +392,14 @@ void InputDefault::set_magnetometer(const Vector3& p_magnetometer) {
|
||||
|
||||
}
|
||||
|
||||
void InputDefault::set_gyroscope(const Vector3& p_gyroscope) {
|
||||
|
||||
_THREAD_SAFE_METHOD_
|
||||
|
||||
gyroscope=p_gyroscope;
|
||||
|
||||
}
|
||||
|
||||
void InputDefault::set_main_loop(MainLoop *p_main_loop) {
|
||||
main_loop=p_main_loop;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user