Added gyroscope support to Godot and Android
This commit is contained in:
parent
4c4ab140b4
commit
370ae3512d
12 changed files with 73 additions and 1 deletions
|
|
@ -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;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue