Table of Contents

Class TouchInfo

Namespace
Fantas.Input
Assembly
Fantas.dll

Contains information about Touch like location, pressure

public sealed class TouchInfo : IEquatable<TouchInfo>
Inheritance
TouchInfo
Implements
Inherited Members

Constructors

TouchInfo(int, TouchState, PointF, TouchDevice, float, float)

Create a TouchInfo

public TouchInfo(int id, TouchState state, PointF location, TouchDevice device, float pressure, float rotation)

Parameters

id int
state TouchState
location PointF
device TouchDevice
pressure float
rotation float

Properties

Device

TouchDevice type (Touch, Mouse, Pen)

public TouchDevice Device { get; }

Property Value

TouchDevice

Id

Touch id number

public int Id { get; }

Property Value

int

Location

Location of the touch, in Screen coordinates

public PointF Location { get; }

Property Value

PointF

Pressure

Get the touch pressure (if available) 0f pressure not available 0.5f - normal pressure 1f - high pressure

public float Pressure { get; }

Property Value

float

Rotation

Get touch rotation if available

public float Rotation { get; }

Property Value

float

State

Current touch state (Down, Move, Up)

public TouchState State { get; }

Property Value

TouchState

Methods

Equals(TouchInfo)

Check if this TouchInfo is equal to the other

public bool Equals(TouchInfo other)

Parameters

other TouchInfo

Returns

bool

Equals(object)

object Equals

public override bool Equals(object obj)

Parameters

obj object

Returns

bool

GetHashCode()

object GetHashCode

public override int GetHashCode()

Returns

int