ManoMotion SDK PRO  1.4.8
ManoMotion SDK PRO API documentation
SkeletonManager Class Reference

Handles the visualization of the skeleton joints. More...

Inheritance diagram for SkeletonManager:

Data Fields

List< GameObject > _listOfJoints = new List<GameObject>()
 The list of joints used for visualization. More...
 

Static Public Attributes

static SkeletonManager instance
 Creates instance of SkeletonManager More...
 

Private Member Functions

void Awake ()
 
void Start ()
 
void Inititialize ()
 
void SkeletonModel (int modelToLoad, int previousModel)
 Create the hand model depending if you use 3D or 2D joints. More...
 
void ResetLineRenderers ()
 Reset the Linerenders when changing Skeleton Model 2D/3D More...
 
void Update ()
 
float radianToDegrees (float radiantValue)
 Calculates the radiant value to degrees More...
 
void UpdateJointorientation ()
 Updates the orientation of the joints according to the orientation given by the SDK. More...
 
void UpdateJointPositions ()
 Updates the position of the joints according to the positions given by the SDK. More...
 

Private Attributes

GameObject[] jointPrefab
 The prefab that will be used for visualization of the joints. More...
 
LineRenderer[] lineRenderers = new LineRenderer[6]
 The linerenderes used on the joints in the jointPrefabs. More...
 
float clampMinDepth = 0.4f
 used to clamp the depth value More...
 
bool hasConfidence
 Skeleton confidence. More...
 
float skeletonConfidenceThreshold = 0.0001f
 
Material[] jointsMaterial
 The materials used on the joints / Line renderers. More...
 
int depthDivider = 10
 Use this to make the depth values smaler to fit the depth of the hand. More...
 
int jointsLength = 21
 The number of Joints the skeleton is made of. More...
 
SkeletonInfo skeletonInfo
 
bool isRightHand = false
 Used to set the current hand detected by the camera. More...
 

Detailed Description

Handles the visualization of the skeleton joints.

Member Function Documentation

◆ Awake()

void SkeletonManager.Awake ( )
inlineprivate

◆ Inititialize()

void SkeletonManager.Inititialize ( )
inlineprivate

◆ radianToDegrees()

float SkeletonManager.radianToDegrees ( float  radiantValue)
inlineprivate

Calculates the radiant value to degrees

Parameters
radiantValuethe radiant value
Returns

◆ ResetLineRenderers()

void SkeletonManager.ResetLineRenderers ( )
inlineprivate

Reset the Linerenders when changing Skeleton Model 2D/3D

◆ SkeletonModel()

void SkeletonManager.SkeletonModel ( int  modelToLoad,
int  previousModel 
)
inlineprivate

Create the hand model depending if you use 3D or 2D joints.

The model need to have 21 joints.

Parameters
modelToLoadThe current model displayed
previousModelThe previous model used

◆ Start()

void SkeletonManager.Start ( )
inlineprivate

◆ Update()

void SkeletonManager.Update ( )
inlineprivate

◆ UpdateJointorientation()

void SkeletonManager.UpdateJointorientation ( )
inlineprivate

Updates the orientation of the joints according to the orientation given by the SDK.

◆ UpdateJointPositions()

void SkeletonManager.UpdateJointPositions ( )
inlineprivate

Updates the position of the joints according to the positions given by the SDK.

If confidence is to low, the joints will fade out.

Field Documentation

◆ _listOfJoints

List<GameObject> SkeletonManager._listOfJoints = new List<GameObject>()

The list of joints used for visualization.

◆ clampMinDepth

float SkeletonManager.clampMinDepth = 0.4f
private

used to clamp the depth value

◆ depthDivider

int SkeletonManager.depthDivider = 10
private

Use this to make the depth values smaler to fit the depth of the hand.

◆ hasConfidence

bool SkeletonManager.hasConfidence
private

Skeleton confidence.

◆ instance

SkeletonManager SkeletonManager.instance
static

Creates instance of SkeletonManager

◆ isRightHand

bool SkeletonManager.isRightHand = false
private

Used to set the current hand detected by the camera.

◆ jointPrefab

GameObject [] SkeletonManager.jointPrefab
private

The prefab that will be used for visualization of the joints.

◆ jointsLength

int SkeletonManager.jointsLength = 21
private

The number of Joints the skeleton is made of.

◆ jointsMaterial

Material [] SkeletonManager.jointsMaterial
private

The materials used on the joints / Line renderers.

◆ lineRenderers

LineRenderer [] SkeletonManager.lineRenderers = new LineRenderer[6]
private

The linerenderes used on the joints in the jointPrefabs.

◆ skeletonConfidenceThreshold

float SkeletonManager.skeletonConfidenceThreshold = 0.0001f
private

◆ skeletonInfo

SkeletonInfo SkeletonManager.skeletonInfo
private

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