mirror of
https://github.com/godotengine/godot.git
synced 2026-01-03 18:11:19 +03:00
[iOS] Add Apple Pencil pressure and tilt support.
This commit is contained in:
@@ -384,6 +384,9 @@ class InputEventScreenDrag : public InputEventFromWindow {
|
||||
Vector2 pos;
|
||||
Vector2 relative;
|
||||
Vector2 velocity;
|
||||
Vector2 tilt;
|
||||
float pressure = 0;
|
||||
bool pen_inverted = false;
|
||||
|
||||
protected:
|
||||
static void _bind_methods();
|
||||
@@ -392,6 +395,15 @@ public:
|
||||
void set_index(int p_index);
|
||||
int get_index() const;
|
||||
|
||||
void set_tilt(const Vector2 &p_tilt);
|
||||
Vector2 get_tilt() const;
|
||||
|
||||
void set_pressure(float p_pressure);
|
||||
float get_pressure() const;
|
||||
|
||||
void set_pen_inverted(bool p_inverted);
|
||||
bool get_pen_inverted() const;
|
||||
|
||||
void set_position(const Vector2 &p_pos);
|
||||
Vector2 get_position() const;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user