JUCE  v5.4.1-191-g0ab5e696f
JUCE API
Looking for a senior C++ dev?
I'm looking for work. Hire me!
juce::TouchSurface::Touch Struct Reference

Structure used to describe touch properties. More...

#include <juce_TouchSurface.h>

Collaboration diagram for juce::TouchSurface::Touch:

Public Attributes

Block::UID blockUID
 The ID of the block that generated this touch. More...
 
Block::Timestamp eventTimestamp
 The timestamp of this event, in milliseconds since the device was booted. More...
 
int index
 A touch index, which will stay constant for each finger as it is tracked. More...
 
bool isTouchEnd
 True if this is the final event as this finger/index is lifted off. More...
 
bool isTouchStart
 True if this is the first event for this finger/index. More...
 
float startX
 The initial X position of the touchStart event corresponding to this finger/index. More...
 
float startY
 The initial Y position of the touchStart event corresponding to this finger/index. More...
 
float x
 The X position of this touch on the device, in logical units starting from 0 (left). More...
 
float xVelocity
 An approximation of the velocity at which the X value is changing, measured in units/second. More...
 
float y
 The Y position of this touch on the device, in logical units starting from 0 (top). More...
 
float yVelocity
 An approximation of the velocity at which the Y value is changing, measured in units/second. More...
 
float z
 The current pressure of this touch, in the range 0.0 (no pressure) to 1.0 (very hard). More...
 
float zVelocity
 The rate at which pressure is currently changing, measured in units/second. More...
 

Detailed Description

Structure used to describe touch properties.

Member Data Documentation

◆ blockUID

Block::UID juce::TouchSurface::Touch::blockUID

The ID of the block that generated this touch.

◆ eventTimestamp

Block::Timestamp juce::TouchSurface::Touch::eventTimestamp

The timestamp of this event, in milliseconds since the device was booted.

◆ index

int juce::TouchSurface::Touch::index

A touch index, which will stay constant for each finger as it is tracked.

◆ isTouchEnd

bool juce::TouchSurface::Touch::isTouchEnd

True if this is the final event as this finger/index is lifted off.

Referenced by juce::TouchList< Type >::updateTouch().

◆ isTouchStart

bool juce::TouchSurface::Touch::isTouchStart

True if this is the first event for this finger/index.

◆ startX

float juce::TouchSurface::Touch::startX

The initial X position of the touchStart event corresponding to this finger/index.

◆ startY

float juce::TouchSurface::Touch::startY

The initial Y position of the touchStart event corresponding to this finger/index.

◆ x

float juce::TouchSurface::Touch::x

The X position of this touch on the device, in logical units starting from 0 (left).

See Block::getWidth() for the maximum X value on the device.

◆ xVelocity

float juce::TouchSurface::Touch::xVelocity

An approximation of the velocity at which the X value is changing, measured in units/second.

This is intended as a useful hint to help with gesture detection, but may be 0 if the device doesn't provide this data.

◆ y

float juce::TouchSurface::Touch::y

The Y position of this touch on the device, in logical units starting from 0 (top).

See Block::getHeight() to find the maximum Y on the device.

◆ yVelocity

float juce::TouchSurface::Touch::yVelocity

An approximation of the velocity at which the Y value is changing, measured in units/second.

This is intended as a useful hint to help with gesture detection, but may be 0 if the device doesn't provide this data.

◆ z

float juce::TouchSurface::Touch::z

The current pressure of this touch, in the range 0.0 (no pressure) to 1.0 (very hard).

◆ zVelocity

float juce::TouchSurface::Touch::zVelocity

The rate at which pressure is currently changing, measured in units/second.

This is intended as a useful hint to help with gesture detection, but may be 0 if the device doesn't provide this data.


The documentation for this struct was generated from the following file: