HExp12-7|Houdini Expression functions全集之Dop节点类:

1、解算器类

float dopsolveobject (float object_index)
返回指定对象的唯一对象标识符。注:对象索引必须大于或等于零,并且小于dopsolvnumnewobjects的返回值。
float dopsolvenewobject (float object_index)
此函数类似于"dopsolveobject",只是它返回需要从脚本解算器初始化的新创建的对象。
float dopsolvenumobjects ()
返回当前正在运行的脚本解算器正在解算的对象数。
float dopsolvenumnewobjects ()
返回当前正在运行的脚本解算器正在初始化的对象数。
string dopsolvedopnet ()
返回包含当前正在运行的脚本解算器的DOP网络的完整路径。
float dopsolvetimestep ()
返回当前正在运行的脚本解算器的时间步长。
2、时间类

float doptime (string dop)
返回模拟的当前时间。
float dopframe (string dop)
返回模拟的当前帧。
float dopframetost (string dop, float simulationframe)
返回模拟帧的等效模拟时间。
float dopsttoframe (string dop, float simulationtime)
返回给定模拟时间的模拟帧。
float dopsttot (string dop, float simulationtime)
返回给定模拟时间的全局时间。
float dopttost (string dop, float globaltime)
返回相当于给定全局时间的模拟时间。
3、Object对象类

string dopobjectlist (string dop, string objectSpec, float listNames)
返回与对象规范匹配的所有对象。
float dopnumobjects (string dop, string objectFilter)
返回模拟中的对象数。
string dopnodeobjs (string dop)
返回DOP在最近的时间步长中处理的对象列表。
string dopobjscreatedby (string dop)
返回由特定DOP节点创建的对象列表。
float dopobjectsareaffectors (string dop, string objectSpec, string affectors)
测试一组对象是否与另一个对象具有影响因素关系。
float dopgrouphasobject (string dop, string objectSpec, string group)
如果指定的DOP组包含指定的对象,则返回1。
4、Subdata子数据与record记录类

string dopsubdataname (string dop, string objectSpec, string subDataName, float subDataNum)
返回给定DOP对象的子数据的名称。
string doprecordtypename (float dop, float objectSpec, float subDataName, float recordTypeNum)
返回DOP数据中给定索引的记录的名称。
float dopnumsubdata (string dop, string objectSpec, string subDataName)
返回附加到对象或数据的子数据项的数目。
float dopnumrecordtypes (string dop, string objectSpec, string subDataName)
返回一段动力学数据中记录的类型数。
float dopnumrecords (string dop, string objectFilter, string subDataName, string recordType)
返回一段动力学数据中给定类型的记录数。
float dophassubdata (string dop, string objectSpec, string subDataName)
如果动力学对象具有指定的子数据,则返回1。
5、Field场类

float dopfield (string dop, string objectSpec, string subDataName, string recordType, float recordNum, string fieldName)
以浮点形式返回场的值。
float dophasfield (string dop, string objectSpec, string subDataName, string recordType, float recordNum, string fieldName)
如果存在指定的场,则返回1。
string dopfields (string dop, string objectSpec, string subDataName, string recordType, float recordNum, string fieldName)
以字符串形式返回场的值。
float dopnumfields (string dop, string objectSpec, string subDataName, string recordType)
返回DOP记录类型中的场数。
string dopallfields (string dop, string objectSpec, string subDataName, string recordType)
返回可以传递给dopfield函数的所有场的名称列表。此列表与dopfieldname函数返回的值不同,因为它包括所有可以访问的子值。例如,如果有一个名为t的向量场,dopfieldname函数只会返回t。这个函数会返回tx-ty-tz(以及所有其他场名称)。
string dopfieldname (string dop, string objectSpec, string subDataName, string recordType, float fieldNum)
返回DOP场的名称。
string dopfieldtype (string dop, string objectSpec, string subDataName, string recordType, float fieldNum)
返回DOP场的类型。
float dopoption (string dop, string objectSpec, string subDataName, string fieldName)
以浮点形式返回DOP场的值。
string dopoptions (string dop, string objectSpec, string subDataName, string fieldName)
以字符串形式返回DOP场的值。
6、其他杂项

string dopgrouplist (string dop)
返回一个字符串,该字符串包含指定DOP网络中当前时间的所有对象组的列表。
float dopgroupismutual (string dop, string group)
如果指定的DOP组相互影响,则返回1。
float dopcountslices (string dop, string objectFilter, string subDataName)
返回在给定数据名称中存储的切片集的情况下,对象应分解为的切片数。每个切片将空间一分为二,但切片的层次结构可能会使总空间的计算变得更加棘手,因此有了这个函数。
matrix doptransform (string dop, string objectSpec, string subDataName)
返回与一段数据关联的变换矩阵。
vector dopvelatpos (string dop, string objectSpec, float posx, float posy, float posz, float usevolumevelocity, float usepointvelocity)
返回模拟空间中某个位置的点在附着到DOP对象时的速度。该速度计算考虑了存储在其位置数据中的模拟对象的速度和角速度。将usevolumevelocity参数设置为非零值会导致返回的速度受到几何体空间速度的影响,该速度是根据几何体体积表示的变化计算得出的。将usepointvelocity参数设置为非零值会导致返回的速度受到对象几何体上的速度属性的影响。几何体速度属性将作为几何体空间速度添加到结果中,几何体空间的速度将添加到“位置”数据中的速度中。如果usedsdfvelocity和usepointvelocity都为非零,则使用sdf速度,而不是点速度。
string dopcontextgeo (string name, float index)
返回连接到dopnetwork的节点的完整路径。这与"opputpath"不同,因为给定的名称应该是dopnet内部节点(或dopnet本身)的名称。这简化了在SOP级别查找连接到dopnet节点的内容的过程。