Example #1
0
///////////////////////////////////////////////////////////////
// SPLINE KINE OP
///////////////////////////////////////////////////////////////
// Define =====================================================
XSIPLUGINCALLBACK CStatus sn_splinekine_op_Define( CRef& in_ctxt )
{
   Context ctxt( in_ctxt );
   CustomOperator op;
   Parameter oParam;
   CRef pdef;

   Factory factory = Application().GetFactory();
   op = ctxt.GetSource();

   pdef = factory.CreateParamDef(L"count",CValue::siInt4,siPersistable | siAnimatable,L"",L"",2,2,100000,2,3);
   op.AddParameter(pdef,oParam);
   pdef = factory.CreateParamDef(L"u",CValue::siDouble,siPersistable | siAnimatable,L"",L"",.5,0,1,0,1);
   op.AddParameter(pdef,oParam);
   pdef = factory.CreateParamDef(L"resample",CValue::siBool,siPersistable | siAnimatable,L"",L"",0,0,1,0,1);
   op.AddParameter(pdef,oParam);
   pdef = factory.CreateParamDef(L"subdiv",CValue::siInt4,siPersistable | siAnimatable,L"",L"",10,3,100000,3,24);
   op.AddParameter(pdef,oParam);
   pdef = factory.CreateParamDef(L"absolute",CValue::siBool,siPersistable | siAnimatable,L"",L"",0,0,1,0,1);
   op.AddParameter(pdef,oParam);

   op.PutAlwaysEvaluate(false);
   op.PutDebug(0);

   return CStatus::OK;
}
Example #2
0
///////////////////////////////////////////////////////////////
// INTER LOCAL ORI
///////////////////////////////////////////////////////////////
// Define =====================================================
XSIPLUGINCALLBACK CStatus sn_interLocalOri_op_Define( CRef& in_ctxt )
{
   Context ctxt( in_ctxt );
   CustomOperator op;
   Parameter param;
   CRef pdef;
   Factory factory = Application().GetFactory();
   op = ctxt.GetSource();

	pdef = factory.CreateParamDef(L"blend",CValue::siDouble,siPersistable|siAnimatable,L"",L"",0.0,  0.0,  1.0,  0.0,  1.0);
	op.AddParameter(pdef,param);

   op.PutAlwaysEvaluate(false);
   op.PutDebug(0);
   return CStatus::OK;
}
///////////////////////////////////////////////////////////////
// INVERSE ROTORDER
///////////////////////////////////////////////////////////////
// Define =====================================================
CStatus sn_inverseRotorder_op_Define( CRef& in_ctxt )
{
   Context ctxt( in_ctxt );
   CustomOperator op;
   Parameter param;
   CRef pdef;
   Factory factory = Application().GetFactory();
   op = ctxt.GetSource();
	pdef = factory.CreateParamDef(L"rotorder",CValue::siInt4,siPersistable|siAnimatable,L"",L"",0,0,5,0,5);
	op.AddParameter(pdef,param);

	op.PutAlwaysEvaluate(false);
	op.PutDebug(0);

	return CStatus::OK;
}
Example #4
0
// Define =====================================================
CStatus gInvRotorderOp_Define( CRef& in_ctxt )
{
    Context ctxt( in_ctxt );
    CustomOperator oCustomOperator;
    Parameter oParam;
    CRef oPDef;
    Factory oFactory = Application().GetFactory();
    oCustomOperator = ctxt.GetSource();

    oCustomOperator = ctxt.GetSource();
    oPDef = oFactory.CreateParamDef(L"Rotorder",CValue::siInt4,siPersistable|siAnimatable,L"",L"",0l,0l,5l,0l,5l);
    oCustomOperator.AddParameter(oPDef,oParam);

    oCustomOperator.PutAlwaysEvaluate(false);
    oCustomOperator.PutDebug(0);
    return CStatus::OK;
}
Example #5
0
/////////////////////////////////////////////////////////////////////////////////////////////
// SOFT IK MULTI (3 and more BONES CHAIN)
/////////////////////////////////////////////////////////////////////////////////////////////
// Define ===================================================================================
CStatus gStretchOp2Multi_Define( CRef& in_ctxt )
{
	Context ctxt( in_ctxt );
	CustomOperator oCustomOperator;
	Parameter oParam;
	CRef oPDef;
	Factory oFactory = Application().GetFactory();
	oCustomOperator = ctxt.GetSource();

	// Initial Settings (Read Only)
	oPDef = oFactory.CreateParamDef(L"restlength",CValue::siDouble,siPersistable | siReadOnly,L"",L"",0.0,0,1000.0,0,10.0);
	oCustomOperator.AddParameter(oPDef,oParam);

	// Animatable Parameters
	oPDef = oFactory.CreateParamDef(L"scale",CValue::siDouble,siPersistable | siAnimatable,L"",L"",1.0,0,1000.0,0,2.0);
	oCustomOperator.AddParameter(oPDef,oParam);
	oPDef = oFactory.CreateParamDef(L"maxstretch",CValue::siDouble,siPersistable | siAnimatable,L"",L"",1.0,1.0,1000.0,1.0,2.0);
	oCustomOperator.AddParameter(oPDef,oParam);
	oPDef = oFactory.CreateParamDef(L"soft",CValue::siDouble,siPersistable | siAnimatable,L"",L"",0.0,0.0,4.0,0.0,1.0);
	oCustomOperator.AddParameter(oPDef,oParam);

	oCustomOperator.PutAlwaysEvaluate(false);
	oCustomOperator.PutDebug(0);

	return CStatus::OK;
}
int CreateSubTreeWithNopCubes( CRef& parentNode, CString& nodeName, CString& path, CString& identifier, int subLevels, int childrenPerLevel, int operatorsPerNode )
{
	X3DObject parentX3DObject(parentNode);
	X3DObject meshObj;

	parentX3DObject.AddGeometry(L"Cube",L"MeshSurface",nodeName,meshObj);
	CRef newNode = meshObj.GetRef();

	CRef realTarget = meshObj.GetActivePrimitive().GetRef();

	for( int i = 0; i < operatorsPerNode; i ++ ) {
		CustomOperator op = Application().GetFactory().CreateObject("exocortex_nop");
		op.AddOutputPort(realTarget);
		op.AddInputPort(realTarget);

		siConstructionMode consMode = siConstructionModeModeling;
		op.Connect(consMode);

		op.PutParameterValue(L"path",path);
		op.PutParameterValue(L"identifier",identifier);
	}

	int numNodes = 1;

	if( subLevels > 0 ) {
		for( int i = 0; i < childrenPerLevel; i ++ ) {
			std::stringstream s;
			s << "node_level" << subLevels << "_child" << i;
			CString childNodeName( s.str().c_str() );
			numNodes += CreateSubTreeWithNopCubes( newNode, childNodeName, path, identifier, subLevels - 1, childrenPerLevel, operatorsPerNode );
		}
	}

	return numNodes ;
}
SICALLBACK exocortex_nop_Define( CRef& in_ctxt )
{
   Context ctxt( in_ctxt );
   CustomOperator oCustomOperator;

   Factory oFactory = Application().GetFactory();
   oCustomOperator = ctxt.GetSource();

	CRef oPDef0 = oFactory.CreateParamDef(L"muted",CValue::siBool,siAnimatable | siPersistable,L"muted",L"muted",0,0,1,0,1);
	CRef  oPDef1 = oFactory.CreateParamDef(L"time",CValue::siFloat,siAnimatable | siPersistable,L"time",L"time",1,-100000,100000,0,1);
	CRef   oPDef2 = oFactory.CreateParamDef(L"path",CValue::siString,siReadOnly | siPersistable,L"path",L"path",L"",L"",L"",L"",L"");
	CRef   oPDef3 = oFactory.CreateParamDef(L"identifier",CValue::siString,siReadOnly | siPersistable,L"identifier",L"identifier",L"",L"",L"",L"",L"");
	CRef   oPDef4 = oFactory.CreateParamDef(L"renderpath",CValue::siString,siReadOnly | siPersistable,L"renderpath",L"renderpath",L"",L"",L"",L"",L"");
	CRef   oPDef5 = oFactory.CreateParamDef(L"renderidentifier",CValue::siString,siReadOnly | siPersistable,L"renderidentifier",L"renderidentifier",L"",L"",L"",L"",L"");

   Parameter oParam;

   oCustomOperator.AddParameter(oPDef0,oParam);
   oCustomOperator.AddParameter(oPDef1,oParam);
   oCustomOperator.AddParameter(oPDef2,oParam);
   oCustomOperator.AddParameter(oPDef3,oParam);
   oCustomOperator.AddParameter(oPDef4,oParam);
   oCustomOperator.AddParameter(oPDef5,oParam);

   oCustomOperator.PutAlwaysEvaluate(false);
   oCustomOperator.PutDebug(0);

   return CStatus::OK;
}
Example #8
0
XSIPLUGINCALLBACK CStatus MomentumConsBallSocket_Define( CRef& in_ctxt )

{

   Context ctxt( in_ctxt );

   CustomOperator oCustomOperator;

   Parameter oParam;

   CRef oPDef;

   Factory oFactory = Application().GetFactory();

   oCustomOperator = ctxt.GetSource();


   oPDef = oFactory.CreateParamDef(L"frame",CValue::siInt4,siAnimatable | siPersistable,L"frame",L"frame",1,-100000,100000,0,1);

   oCustomOperator.AddParameter(oPDef,oParam);

   oPDef = oFactory.CreateParamDef(L"secondaryA",CValue::siInt4,siPersistable,L"secondaryA",L"secondaryA",-1,-1,100000,-1,1000);

   oCustomOperator.AddParameter(oPDef,oParam);

   oPDef = oFactory.CreateParamDef(L"secondaryB",CValue::siInt4,siPersistable,L"secondaryB",L"secondaryB",-1,-1,100000,-1,1000);

   oCustomOperator.AddParameter(oPDef,oParam);


   oCustomOperator.PutAlwaysEvaluate(false);

   oCustomOperator.PutDebug(0);

   return CStatus::OK;

}
Example #9
0
XSIPLUGINCALLBACK CStatus apply_MomentumConsBallSocket_Execute( CRef& in_ctxt )

{

   Context ctxt( in_ctxt );

   Selection l_pSelection = Application().GetSelection();

   // you need to select TWO objects
   if(l_pSelection.GetCount() != 2)
   {
      Application().LogMessage(L"[MOMENTUM] You need to select TWO rigid bodies.",siErrorMsg);
      return CStatus::Abort;
   }

   X3DObject obj1(l_pSelection.GetItem(0));

   X3DObject obj2(l_pSelection.GetItem(1));
   CRef opRef1,opRef2;
   opRef1.Set(obj1.GetFullName()+L".kine.global.MomentumKinematics");
   if(!opRef1.IsValid())

      opRef1.Set(obj1.GetFullName()+L".polymsh.MomentumDeform");
   opRef2.Set(obj2.GetFullName()+L".kine.global.MomentumKinematics");
   if(!opRef2.IsValid())

      opRef2.Set(obj2.GetFullName()+L".polymsh.MomentumDeform");
   if(!opRef1.IsValid())
   {
      Application().LogMessage(L"[MOMENTUM] Object "+obj1.GetFullName()+L" is not a bullet rigid body.",siErrorMsg);
      return CStatus::Abort;

   }
   if(!opRef2.IsValid())
   {
      Application().LogMessage(L"[MOMENTUM] Object "+obj1.GetFullName()+L" is not a bullet rigid body.",siErrorMsg);
      return CStatus::Abort;

   }

   // get the transform for the cons
   CTransformation xfA = obj1.GetKinematics().GetGlobal().GetTransform();
   CTransformation xfB = obj2.GetKinematics().GetGlobal().GetTransform();
   CVector3 trans;
   trans.LinearlyInterpolate(xfA.GetTranslation(),xfB.GetTranslation(),0.5);
   xfA.SetTranslation(trans);

   // create the constraint object
   Null consNull1;
   obj1.AddNull(L"BallSocket_pivot",consNull1);
   consNull1.GetKinematics().GetGlobal().PutTransform(xfA);
   consNull1.GetActivePrimitive().PutParameterValue(L"primary_icon", (LONG)2);

   // create the operator

   CustomOperator newOp = Application().GetFactory().CreateObject(L"MomentumConsBallSocket");

   newOp.AddOutputPort(consNull1.GetKinematics().GetGlobal().GetRef());

   newOp.AddInputPort(consNull1.GetKinematics().GetGlobal().GetRef());

   newOp.AddInputPort(obj1.GetKinematics().GetGlobal().GetRef());

   newOp.AddInputPort(obj2.GetKinematics().GetGlobal().GetRef());

   newOp.AddInputPort(opRef1);

   newOp.AddInputPort(opRef2);

   newOp.Connect();

   // set the expression for the frame!
   CValueArray args(2);
   CValue returnVal;
   args[0] = newOp.GetFullName()+L".frame";
   args[1] = L"fc";
   Application().ExecuteCommand(L"SetExpr",args,returnVal);

   return CStatus::OK;

}
///////////////////////////////////////////////////////////////
// SQUASH STRETCH
///////////////////////////////////////////////////////////////
// Define =====================================================
XSIPLUGINCALLBACK CStatus sn_squashstretch_op_Define( CRef& in_ctxt )
{
   Context ctxt( in_ctxt );
   CustomOperator oCustomOperator;
   Parameter oParam;
   CRef oPDef;
   Factory oFactory = Application().GetFactory();
   oCustomOperator = ctxt.GetSource();
   oPDef = oFactory.CreateParamDef(L"blend",CValue::siDouble,siPersistable | siAnimatable,L"",L"",1,0,1,0,1);
   oCustomOperator.AddParameter(oPDef,oParam);
   oPDef = oFactory.CreateParamDef(L"driver",CValue::siDouble,siPersistable | siAnimatable,L"",L"",0,-100000,100000,0,24);
   oCustomOperator.AddParameter(oPDef,oParam);
   oPDef = oFactory.CreateParamDef(L"u",CValue::siDouble,siPersistable | siAnimatable,L"",L"",50,0,100,0,100);
   oCustomOperator.AddParameter(oPDef,oParam);
   oPDef = oFactory.CreateParamDef(L"sq_min",CValue::siDouble,siPersistable | siAnimatable,L"",L"",0,-100000,100000,0,1);
   oCustomOperator.AddParameter(oPDef,oParam);
   oPDef = oFactory.CreateParamDef(L"sq_max",CValue::siDouble,siPersistable | siAnimatable,L"",L"",5,-100000,100000,0,1);
   oCustomOperator.AddParameter(oPDef,oParam);
   oPDef = oFactory.CreateParamDef(L"sq_y",CValue::siDouble,siPersistable | siAnimatable,L"",L"",1,-100000,100000,0,1);
   oCustomOperator.AddParameter(oPDef,oParam);
   oPDef = oFactory.CreateParamDef(L"sq_z",CValue::siDouble,siPersistable | siAnimatable,L"",L"",1,-100000,100000,0,1);
   oCustomOperator.AddParameter(oPDef,oParam);
   oPDef = oFactory.CreateParamDef(L"st_min",CValue::siDouble,siPersistable | siAnimatable,L"",L"",5,-100000,100000,0,1);
   oCustomOperator.AddParameter(oPDef,oParam);
   oPDef = oFactory.CreateParamDef(L"st_max",CValue::siDouble,siPersistable | siAnimatable,L"",L"",10,-100000,100000,0,1);
   oCustomOperator.AddParameter(oPDef,oParam);
   oPDef = oFactory.CreateParamDef(L"st_y",CValue::siDouble,siPersistable | siAnimatable,L"",L"",.5,-100000,100000,1,5);
   oCustomOperator.AddParameter(oPDef,oParam);
   oPDef = oFactory.CreateParamDef(L"st_z",CValue::siDouble,siPersistable | siAnimatable,L"",L"",.5,-100000,100000,1,5);
   oCustomOperator.AddParameter(oPDef,oParam);

   oCustomOperator.PutAlwaysEvaluate(false);
   oCustomOperator.PutDebug(0);
   return CStatus::OK;
}
Example #11
0
///////////////////////////////////////////////////////////////
// IK FK 2 BONE OP
///////////////////////////////////////////////////////////////
// Define =====================================================
XSIPLUGINCALLBACK CStatus sn_ikfk2bone_op_Define( CRef& in_ctxt )
{
   Context ctxt( in_ctxt );
   CustomOperator op;
   Parameter param;
   CRef pdef;
   Factory factory = Application().GetFactory();
   op = ctxt.GetSource();

	pdef = factory.CreateParamDef(L"lengthA",CValue::siDouble,siPersistable|siAnimatable,L"",L"",3.0, 0.0, 999999.0, 0.0, 10.0);
	op.AddParameter(pdef,param);
	pdef = factory.CreateParamDef(L"lengthB",CValue::siDouble,siPersistable|siAnimatable,L"",L"",5.0, 0.0, 999999.0, 0.0, 10.0);
	op.AddParameter(pdef,param);
	pdef = factory.CreateParamDef(L"negate",CValue::siBool,siPersistable|siAnimatable,L"",L"",false);
	op.AddParameter(pdef,param);

   pdef = factory.CreateParamDef(L"blend",CValue::siDouble,siPersistable | siAnimatable,L"",L"",0.0, 0.0,1.0, 0.0, 1.0);
   op.AddParameter(pdef,param);

	pdef = factory.CreateParamDef(L"roll",CValue::siDouble,siPersistable|siAnimatable,L"",L"",0.0,  -360.0,  360.0,  -360.0,  360.0);
	op.AddParameter(pdef,param);

	pdef = factory.CreateParamDef(L"scaleA",CValue::siDouble,siPersistable|siAnimatable,L"",L"",1.0, 0.0, 999999.0, 0.0, 2.0);
	op.AddParameter(pdef,param);
	pdef = factory.CreateParamDef(L"scaleB",CValue::siDouble,siPersistable|siAnimatable,L"",L"",1.0, 0.0, 999999.0, 0.0, 2.0);
	op.AddParameter(pdef,param);

	pdef = factory.CreateParamDef(L"maxstretch",CValue::siDouble,siPersistable|siAnimatable,L"",L"",1.0, 1.0, 999999.0, 1.0, 2.0);
	op.AddParameter(pdef,param);
	pdef = factory.CreateParamDef(L"softness",CValue::siDouble,siPersistable|siAnimatable,L"",L"",0.0, 0.0, 999999.0, 0.0, 1.0);
	op.AddParameter(pdef,param);
	pdef = factory.CreateParamDef(L"slide",CValue::siDouble,siPersistable|siAnimatable,L"",L"",0.5,0.0, 1.0, 0.0, 1.0);
	op.AddParameter(pdef,param);
	pdef = factory.CreateParamDef(L"reverse",CValue::siDouble,siPersistable|siAnimatable,L"",L"",0.0, 0.0, 1.0, 0.0, 1.0);
	op.AddParameter(pdef,param);

   op.PutAlwaysEvaluate(false);
   op.PutDebug(0);
   return CStatus::OK;
}
Example #12
0
///////////////////////////////////////////////////////////////
// NULL 2 CURVE
///////////////////////////////////////////////////////////////
// Define =====================================================
XSIPLUGINCALLBACK CStatus sn_null2curve_op_Define( CRef& in_ctxt )
{
   Context ctxt( in_ctxt );
   CustomOperator op;
   Parameter param;
   CRef pdef;
   Factory oFactory = Application().GetFactory();
   op = ctxt.GetSource();
   pdef = oFactory.CreateParamDef(L"blend",CValue::siDouble,siPersistable | siAnimatable,L"",L"",0,0,1,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"u",CValue::siDouble,siPersistable | siAnimatable,L"",L"",.5,0,1,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"imin",CValue::siDouble,siPersistable | siAnimatable,L"",L"",0,0,1,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"imax",CValue::siDouble,siPersistable | siAnimatable,L"",L"",1,0,1,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"omin",CValue::siDouble,siPersistable | siAnimatable,L"",L"",0,0,1,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"omax",CValue::siDouble,siPersistable | siAnimatable,L"",L"",1,0,1,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"soft_blend",CValue::siDouble,siPersistable | siAnimatable,L"",L"",.5,0,1,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"upv_mode",CValue::siInt4,siPersistable | siAnimatable,L"",L"",0,0,100000,0,10);
   op.AddParameter(pdef,param);

   op.PutAlwaysEvaluate(false);
   op.PutDebug(0);
   return CStatus::OK;
}
Example #13
0
///////////////////////////////////////////////////////////////
// NULL 2 SURFACE
///////////////////////////////////////////////////////////////
// Define =====================================================
XSIPLUGINCALLBACK CStatus sn_null2surface_op_Define( CRef& in_ctxt )
{
   Context ctxt( in_ctxt );
   CustomOperator op;
   Parameter param;
   CRef pdef;
   Factory oFactory = Application().GetFactory();
   op = ctxt.GetSource();
   pdef = oFactory.CreateParamDef(L"blend",CValue::siDouble,siPersistable | siAnimatable,L"",L"",0,0,1,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"u",CValue::siDouble,siPersistable | siAnimatable,L"",L"",.5,0,1,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"v",CValue::siDouble,siPersistable | siAnimatable,L"",L"",.5,0,1,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"input_mode",CValue::siInt4,siPersistable | siAnimatable,L"",L"",0,0,100000,0,10);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"iu_center",CValue::siDouble,siPersistable | siAnimatable,L"",L"",.5,0,1,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"iv_center",CValue::siDouble,siPersistable | siAnimatable,L"",L"",.5,0,1,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"iu_variance",CValue::siDouble,siPersistable | siAnimatable,L"",L"",1,0,10,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"iv_variance",CValue::siDouble,siPersistable | siAnimatable,L"",L"",1,0,10,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"i0_minmax",CValue::siBool,siPersistable | siAnimatable,L"",L"",0,0,1,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"ix_center",CValue::siDouble,siPersistable | siAnimatable,L"",L"",0,-1000,1000,-2,2);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"iy_center",CValue::siDouble,siPersistable | siAnimatable,L"",L"",0,-1000,1000,-2,2);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"ix_variance",CValue::siDouble,siPersistable | siAnimatable,L"",L"",8,0,1000,0,10);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"iy_variance",CValue::siDouble,siPersistable | siAnimatable,L"",L"",8,0,1000,0,10);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"ix_invert",CValue::siBool,siPersistable | siAnimatable,L"",L"",0,0,1,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"iy_invert",CValue::siBool,siPersistable | siAnimatable,L"",L"",1,0,1,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"axis_mode",CValue::siInt4,siPersistable | siAnimatable,L"",L"",1,0,100000,0,10);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"i1_minmax",CValue::siBool,siPersistable | siAnimatable,L"",L"",0,0,1,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"ou_center",CValue::siDouble,siPersistable | siAnimatable,L"",L"",.5,0,1,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"ov_center",CValue::siDouble,siPersistable | siAnimatable,L"",L"",.5,0,1,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"ou_variance",CValue::siDouble,siPersistable | siAnimatable,L"",L"",1,0,10,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"ov_variance",CValue::siDouble,siPersistable | siAnimatable,L"",L"",1,0,10,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"o_minmax",CValue::siBool,siPersistable | siAnimatable,L"",L"",0,0,1,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"surf_index",CValue::siInt4,siPersistable | siAnimatable,L"",L"",0,0,100000,0,10);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"upv_mode",CValue::siInt4,siPersistable | siAnimatable,L"",L"",0,0,100000,0,10);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"upv_offsetu",CValue::siDouble,siPersistable | siAnimatable,L"",L"",0,-1,1,-.5,.5);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"upv_offsetv",CValue::siDouble,siPersistable | siAnimatable,L"",L"",0,-1,1,-.5,.5);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"upv_debug_pos",CValue::siBool,siPersistable | siAnimatable,L"",L"",0,0,1,0,1);
   op.AddParameter(pdef,param);
   pdef = oFactory.CreateParamDef(L"scl_mode",CValue::siInt4,siPersistable | siAnimatable,L"",L"",1,0,100000,0,10);
   op.AddParameter(pdef,param);

   op.PutAlwaysEvaluate(false);
   op.PutDebug(0);
   return CStatus::OK;
}