summaryrefslogtreecommitdiff
path: root/servers/xr
diff options
context:
space:
mode:
authorBastiaan Olij <mux213@gmail.com>2021-12-14 12:44:12 +1100
committerRĂ©mi Verschelde <rverschelde@gmail.com>2022-02-23 12:02:24 +0100
commita78a9fee7194297fca8867b4983deb4da0ba18c2 (patch)
tree342d988883aa6779b8c2014c3723dfcbf97116fa /servers/xr
parent65bae5a3411a6fd2dbfc9f8e364040024fa81b04 (diff)
Implementing OpenXR driver
Diffstat (limited to 'servers/xr')
-rw-r--r--servers/xr/xr_positional_tracker.cpp17
-rw-r--r--servers/xr/xr_positional_tracker.h8
2 files changed, 0 insertions, 25 deletions
diff --git a/servers/xr/xr_positional_tracker.cpp b/servers/xr/xr_positional_tracker.cpp
index 7b21eeba04..671eb7a111 100644
--- a/servers/xr/xr_positional_tracker.cpp
+++ b/servers/xr/xr_positional_tracker.cpp
@@ -65,10 +65,6 @@ void XRPositionalTracker::_bind_methods() {
ADD_SIGNAL(MethodInfo("button_released", PropertyInfo(Variant::STRING, "name")));
ADD_SIGNAL(MethodInfo("input_value_changed", PropertyInfo(Variant::STRING, "name"), PropertyInfo(Variant::FLOAT, "value")));
ADD_SIGNAL(MethodInfo("input_axis_changed", PropertyInfo(Variant::STRING, "name"), PropertyInfo(Variant::VECTOR2, "vector")));
-
- ClassDB::bind_method(D_METHOD("get_rumble"), &XRPositionalTracker::get_rumble);
- ClassDB::bind_method(D_METHOD("set_rumble", "rumble"), &XRPositionalTracker::set_rumble);
- ADD_PROPERTY(PropertyInfo(Variant::FLOAT, "rumble"), "set_rumble", "get_rumble");
};
void XRPositionalTracker::set_tracker_type(XRServer::TrackerType p_type) {
@@ -206,21 +202,8 @@ void XRPositionalTracker::set_input(const StringName &p_action_name, const Varia
}
}
-real_t XRPositionalTracker::get_rumble() const {
- return rumble;
-};
-
-void XRPositionalTracker::set_rumble(real_t p_rumble) {
- if (p_rumble > 0.0) {
- rumble = p_rumble;
- } else {
- rumble = 0.0;
- };
-};
-
XRPositionalTracker::XRPositionalTracker() {
type = XRServer::TRACKER_UNKNOWN;
name = "Unknown";
hand = TRACKER_HAND_UNKNOWN;
- rumble = 0.0;
};
diff --git a/servers/xr/xr_positional_tracker.h b/servers/xr/xr_positional_tracker.h
index 2f358cbb21..ccb30bbbe6 100644
--- a/servers/xr/xr_positional_tracker.h
+++ b/servers/xr/xr_positional_tracker.h
@@ -62,10 +62,6 @@ private:
Map<StringName, Ref<XRPose>> poses;
Map<StringName, Variant> inputs;
- int joy_id; // if we also have a related joystick entity, the id of the joystick
- Ref<Mesh> mesh; // when available, a mesh that can be used to render this tracker
- real_t rumble; // rumble strength, 0.0 is off, 1.0 is maximum, note that we only record here, xr_interface is responsible for execution
-
protected:
static void _bind_methods();
@@ -87,10 +83,6 @@ public:
Variant get_input(const StringName &p_action_name) const;
void set_input(const StringName &p_action_name, const Variant &p_value);
- // TODO replace by new implementation
- real_t get_rumble() const;
- void set_rumble(real_t p_rumble);
-
XRPositionalTracker();
~XRPositionalTracker() {}
};