## SetNeutralPose

### Description

Copies all or parts of the current local transform to the neutral pose transform. It also recalculates the local transform based on the new neutral pose. The neutral pose acts like an intermediate parent between an object and its real parent. Neutral pose transform values are relative the parent object.
An object's neutral pose is the pose where the local transform is identity. In Softimage the default neutral pose is the object's parent pose. Local animation is relative the object's neutral pose.
Use ResetTransform to reset an object to its neutral pose.

### Scripting Syntax

    SetNeutralPose( [InputObjs], [Type], [Reset] );

### Parameters

Parameter | Type | Description
--- | --- | ---
InputObjs | String | List of objects or components. Default Value: Selected elements
Type | siTransformFilter | Specifies the type of transformation to reset Default Value: siSRT
Reset | Boolean | False = Set the neutral pose, True = Reset the neutral pose. Default Value: False

### Examples

#### JScript Example

    //
    // This script creates a cone, sets a pose, copies the local transform
    // into the neutral pose (which will zero-out the local transform), then
    // resets the neutral pose (which will restore the local transform).
    //
    var oMyCone = CreatePrim("Cone", "MeshSurface")
    Translate(oMyCone, 1,2,3,siRelative, siView, siObj, siXYZ, null, null, null, null, null, null, null, null, null);
    Rotate(oMyCone, 10, 20, 30, siRelative, siLocal, siObj, siXYZ, null, null, null, null, null, null, null);
    LogMessage("Original");
    LogPosAndRot(oMyCone);
    //set the current pose as the neutral pose
    SetNeutralPose(oMyCone, siSRT, false);
    LogMessage("After setting neutral pose");
    LogPosAndRot(oMyCone);
    //reset the neutral pose
    SetNeutralPose(oMyCone, siSRT, true);
    LogMessage("After resetting neutral pose");
    LogPosAndRot(oMyCone);
    //--------------------------------------------//
    // log the local position and rotation,           //
    // and the neutral pose position and rotation //
    //--------------------------------------------//
    function LogPosAndRot( in_obj )
    {
            LogMessage("Local Position:" +
                       " (" + GetValue(in_obj+ ".kine.local.posx") +
                       " ," + GetValue(in_obj+ ".kine.local.posy") +
                       " ," + GetValue(in_obj+ ".kine.local.posz") + ")");
            LogMessage("Local Rotation:" +
                       " (" + GetValue(in_obj+ ".kine.local.rotx") +
                       " ," + GetValue(in_obj+ ".kine.local.roty") +
                       " ," + GetValue(in_obj+ ".kine.local.rotz") + ")");
            LogMessage("Neutral Position:" +
                       " (" + GetValue(in_obj+ ".kine.local.nposx") +
                       " ," + GetValue(in_obj+ ".kine.local.nposy") +
                       " ," + GetValue(in_obj+ ".kine.local.nposz") + ")");
            LogMessage("Neutral Rotation:" +
                       " (" + GetValue(in_obj+ ".kine.local.nrotx") +
                       " ," + GetValue(in_obj+ ".kine.local.nroty") +
                       " ," + GetValue(in_obj+ ".kine.local.nrotz") + ")");
            LogMessage ("--------------------------");
    }
    //
    // Output from this script:
    //
    //INFO : "Original"
    //INFO : "Local Position: (1 ,2 ,3)"
    //INFO : "Local Rotation: (10 ,20 ,30)"
    //INFO : "Neutral Position: (0 ,0 ,0)"
    //INFO : "Neutral Rotation: (0 ,0 ,0)"
    //INFO : "--------------------------"
    //INFO : "After setting neutral pose"
    //INFO : "Local Position: (0 ,0 ,0)"
    //INFO : "Local Rotation: (0 ,0 ,0)"
    //INFO : "Neutral Position: (1 ,2 ,3)"
    //INFO : "Neutral Rotation: (10 ,20 ,30)"
    //INFO : "--------------------------"
    //INFO : "After resetting neutral pose"
    //INFO : "Local Position: (1 ,2 ,3)"
    //INFO : "Local Rotation: (10 ,20 ,30)"
    //INFO : "Neutral Position: (0 ,0 ,0)"
    //INFO : "Neutral Rotation: (0 ,0 ,0)"
    //INFO : "--------------------------"

### See Also

ResetTransform