Creature Control for Unity v0.1
Loading...
Searching...
No Matches
Creatures.LegTarget Class Reference

Description

A leg in a TargetRig which is used to control a leg in a model.

Inheritance diagram for Creatures.LegTarget:
Creatures.Target

Public Member Functions

override void PoseTarget ()
 Pose the target limb.
virtual void Align ()
 Align the pose.

Static Public Member Functions

static float CosineRule (float a, float b, float c)
 Implementation of the Law of Cosines.

Public Attributes

Transform girdle
 The target for the girdle bone.
Vector3 girdleAxis
 The girdle axis is the axis for the forward/backward movement.
Bone.RangeOfMotion girdleROM = new(-80, 80)
 The range of motion for the girdle bone.
Transform upper
 The target for the upper bone.
Bone.RangeOfMotion upperROM = new(0, 170)
 The upper bone right axis is the axis for lifting the leg.
float upperLength
 The length of the upper bone.
Transform lower
 The target for the lower bone.
Transform lowerEnd
 The end transform of the lower bone.
float lowerLength
 The length of the lower bone.
Bone.RangeOfMotion lowerROM = new(0, 170)
 The range of motion of the lower bone.
Transform extremity
 The target for the extremity.
Transform extremityEnd
 The end transform of the extremity.
float extremityLength
 The length fo the extremity target.
Transform phalanges
 The target for the phalanges bone.
Transform end
 The end target of the leg chain.
float length
 The length of the leg from hip to foot.
float kneeEndDistance
 The distance between the lower bone and the end of the chain.
Quaternion lowerToEndRotation
 Rotates the tibia from foot to toe position.
Transform ikTarget
 The target for the inverse kinematics.
Side side
 The Side of of body where this leg is located.
LegTarget otherSide
 The target of the leg on the other Side of the body.
Rig rig
 The target Rig to which this target belongs.
bool isMatched = false
 Is this target matched to a bone?

Protected Member Functions

void PoseTargetGirdle ()
 Calculate the girdle target orientation in world space.
void PoseTargetUpper ()
 Calculate the upper target orientation in world space.
void PoseTargetLower ()
 Calculate the lower target orientation in world space.
void PoseTargetExtremity ()
 Calculates the extremity rotation in world space.

Member Function Documentation

◆ PoseTarget()

override void Creatures.LegTarget.PoseTarget ( )
virtual

Pose the target limb.

Reimplemented from Creatures.Target.

◆ CosineRule()

float Creatures.LegTarget.CosineRule ( float a,
float b,
float c )
static

Implementation of the Law of Cosines.

Parameters
aSide a of the triangle
bSide b of the triangle
cSide c of the triangle
Returns
The angle between sides a and b

◆ Align()

virtual void Creatures.Target.Align ( )
virtualinherited

Align the pose.

This will make the pose of the creature symmetric

Reimplemented in Creatures.HeadTarget, Creatures.Insects.HeadTarget, and Creatures.TailTarget.

Member Data Documentation

◆ girdle

Transform Creatures.LegTarget.girdle

The target for the girdle bone.

Another name is the coxa, hip or shoulder bone

◆ upper

Transform Creatures.LegTarget.upper

The target for the upper bone.

Another name is the femur, upper leg or thigh

◆ upperROM

Bone.RangeOfMotion Creatures.LegTarget.upperROM = new(0, 170)

The upper bone right axis is the axis for lifting the leg.

The range of motion of the upper bone

◆ lower

Transform Creatures.LegTarget.lower

The target for the lower bone.

Another name is the lower leg or shank

◆ extremity

Transform Creatures.LegTarget.extremity

The target for the extremity.

Another name is the foot

◆ phalanges

Transform Creatures.LegTarget.phalanges

The target for the phalanges bone.

Another name is the toes No individual toe bones are supported

This target is currently not supported

◆ length

float Creatures.LegTarget.length

The length of the leg from hip to foot.

This is used for the inverse kinematics calculations

◆ ikTarget

Transform Creatures.LegTarget.ikTarget

The target for the inverse kinematics.

This target is normalle at the foot bone


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