Class AbstractHandModel
Class that manages the display of the hand
Inheritance
Implements
Namespace: TofAr.V0.Hand
Assembly: TofArHandAssembly.dll
Syntax
public abstract class AbstractHandModel : MonoBehaviour, IHandModel
Fields
autoMode
true: Automatic playback mode
Default: false
Declaration
public bool autoMode
Field Value
Type |
---|
System.Boolean |
autoPoints
Automatic playback mode points
Declaration
public Vector3[] autoPoints
Field Value
Type |
---|
UnityEngine.Vector3[] |
handPoints
Hand points
Declaration
protected Vector3[] handPoints
Field Value
Type |
---|
UnityEngine.Vector3[] |
handStatus
Hand recognition status
Declaration
[HideInInspector]
public HandStatus handStatus
Field Value
Type |
---|
HandStatus |
Properties
AutoRotate
true: HandModel automatically rotates according to the device orientation
false: Do not automatically rotate
Default: false
Declaration
public bool AutoRotate { get; set; }
Property Value
Type |
---|
System.Boolean |
HandPoints
Array of hand points
Declaration
public Vector3[] HandPoints { get; }
Property Value
Type |
---|
UnityEngine.Vector3[] |
IsHandDetected
true: Hand is detected
false: Is not detected
Declaration
public bool IsHandDetected { get; }
Property Value
Type |
---|
System.Boolean |
LRHand
Hand recognition status
Declaration
public HandStatus LRHand { get; set; }
Property Value
Type |
---|
HandStatus |
WorldHandPoints
Array of hand points (world coordinates)
Declaration
public Vector3[] WorldHandPoints { get; }
Property Value
Type |
---|
UnityEngine.Vector3[] |
Methods
DoAutoRotate()
Screen orientation
Declaration
protected void DoAutoRotate()
DrawHandModel()
Draw hand model
Declaration
protected abstract void DrawHandModel()
LateUpdate()
Executed after the Update method has been called
Declaration
protected virtual void LateUpdate()
OnDisable()
Called when object is disabled
Declaration
protected virtual void OnDisable()
OnEnable()
Called when object is enabled
Declaration
protected virtual void OnEnable()
OnHandsCalculated(Vector3[], HandStatus)
Hand points calculated
Declaration
protected void OnHandsCalculated(Vector3[] points, HandStatus handStatus)
Parameters
Type | Name | Description |
---|---|---|
UnityEngine.Vector3[] | points | Position |
HandStatus | handStatus | Hand recognition status |
OnScreenRotationChanged(ScreenOrientation, ScreenOrientation)
Screen rotated
Declaration
protected void OnScreenRotationChanged(ScreenOrientation previousOrientation, ScreenOrientation newOrientation)
Parameters
Type | Name | Description |
---|---|---|
UnityEngine.ScreenOrientation | previousOrientation | Screen orientation before |
UnityEngine.ScreenOrientation | newOrientation | Screen orientation after |
SetupHandCalcCallbacks()
Setup hand calculation callbacks
Declaration
protected virtual void SetupHandCalcCallbacks()