Class TAbstractTouchSensorNode

Unit

Declaration

type TAbstractTouchSensorNode = class(TAbstractPointingDeviceSensorNode)

Description

Base type for all touch-style pointing device sensors.

Hierarchy

Overview

Methods

Public constructor Create(const AX3DName: string = ''; const ABaseUrl: string = ''); override;
Public procedure CreateNode; override;
Public class function ClassX3DType: string; override;

Properties

Public property OnClick: TNotifyEvent read FOnClick write FOnClick;
Public property EventTouchTime: TSFTimeEvent read FEventTouchTime;

Description

Methods

Public constructor Create(const AX3DName: string = ''; const ABaseUrl: string = ''); override;
 
Public procedure CreateNode; override;

Automatically generated node properties.

Do not edit this file manually! To add new properties: - add them to the text files in tools/internal/x3d-nodes-to-pascal/nodes-specification/ , - and regenerate include files by running x3d-nodes-to-pascal

Public class function ClassX3DType: string; override;
 

Properties

Public property OnClick: TNotifyEvent read FOnClick write FOnClick;

Event generated when we register a "click" on the shapes within the same group as this TouchSensor node. The "click" definition corresponds to the X3D touchTime event generation.

Note that, in order to register clicks, TCastleScene must be configured to process events (TCastleSceneCore.ProcessEvents) and be able to detect clicks on particular shapes (TCastleSceneCore.Spatial should contain ssDynamicCollisions). Usually you will initialize scene like this:

MyScene := TCastleScene.Create(...);
MyScene.Load(...); // load X3D graph with TouchSensor node
MyScene.Spatial := [ssRendering, ssDynamicCollisions];
MyScene.ProcessEvents := true;

Public property EventTouchTime: TSFTimeEvent read FEventTouchTime;
 

Generated by PasDoc 0.16.0.