Struct TouchPoint
Represents data for touchscreen events
Assembly: Meadow.Contracts.dll
View Source
public readonly struct TouchPoint : IEquatable<TouchPoint?>, IEquatable<TouchPoint>
Implements:
System.IEquatable<System.Nullable<Meadow.Hardware.TouchPoint>>
, System.IEquatable<Meadow.Hardware.TouchPoint>
Properties
RawX
Gets the raw X position data of the touch point
View Source
public int RawX { get; }
RawY
Gets the raw Y position data of the touch point
View Source
public int RawY { get; }
RawZ
Gets the raw Z position data of the touch point
View Source
public int? RawZ { get; }
ScreenX
Gets the screen-coordinate X position of the touch point
View Source
public int ScreenX { get; }
ScreenY
Gets the screen-coordinate Y position of the touch point
View Source
public int ScreenY { get; }
ScreenZ
Gets the screen-coordinate Z position of the touch point
View Source
public int? ScreenZ { get; }
Methods
FromRawData(int, int, int?)
Creates a TouchPoint from raw touchscreen data
View Source
public static TouchPoint FromRawData(int rawX, int rawY, int? rawZ)
Returns
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | rawX | The raw X position data |
System.Int32 | rawY | The raw Y position data |
System.Nullable<System.Int32> | rawZ | The raw Z position data |
FromScreenData(int, int, int, int, int, int?)
Creates a TouchPoint from screen coordinates and raw screen data
View Source
public static TouchPoint FromScreenData(int screenX, int screenY, int screenZ, int rawX, int rawY, int? rawZ)
Returns
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | screenX | The X screen position |
System.Int32 | screenY | The Y screen position |
System.Int32 | screenZ | The Z screen position |
System.Int32 | rawX | The raw X position data |
System.Int32 | rawY | The raw Y position data |
System.Nullable<System.Int32> | rawZ | The raw Z position data |
Equals(TouchPoint)
Indicates whether the current object is equal to another object of the same type.
View Source
public bool Equals(TouchPoint other)
Returns
System.Boolean
: true if the current object is equal to the <code class="paramref">other</code> parameter; otherwise, false.
Parameters
Type | Name | Description |
---|---|---|
Meadow.Hardware.TouchPoint | other | An object to compare with this object. |
Equals(TouchPoint?)
Indicates whether the current object is equal to another object of the same type.
View Source
public bool Equals(TouchPoint? other)
Returns
System.Boolean
: true if the current object is equal to the <code class="paramref">other</code> parameter; otherwise, false.
Parameters
Type | Name | Description |
---|---|---|
System.Nullable<Meadow.Hardware.TouchPoint> | other | An object to compare with this object. |
ToString()
Returns the fully qualified type name of this instance.
View Source
public override string ToString()
Returns
System.String
: The fully qualified type name.
Implements
System.IEquatable<System.Nullable<Meadow.Hardware.TouchPoint>>
System.IEquatable<Meadow.Hardware.TouchPoint>