This command creates a blind data type, which is represented by a blindDataTemplate node in the DG. A blind data type can have one or more attributes. On the command line, the attributes should be ordered by type for best memory utilization, largest first: string, binary, double, float, int, and finally boolean. Once a blind data type is created, blind data of that type may be assigned using the polyBlindData command. Note that as well as polygon components, blind data may be assigned to objects and to NURBS patches. A blind data type may not be modified after it is created: in order to do so it must be deleted and recreated. Any existing blind data of that type would also need to be deleted and recreated. When used with the query flag, this command will return information about the attributes of the specified blind data type.
Long name (short name) | Argument Types | Properties | |
---|---|---|---|
dataType (dt) | unicode | ||
Specifies the dataTypes that are part of BlindData node being created. Allowable strings are “int”, “float”, “double”, “string”, “boolean” and “binary”. Must be used togeter with the -ldn and -sdn flags to specify each attribute. |
|||
longDataName (ldn) | unicode | ||
|
|||
longNames (ln) | bool | ||
|
|||
shortDataName (sdn) | unicode | ||
Specifies the short names of the data that are part of BlindData node being created. Must be used togeter with the -dt and -ldn flags to specify each attribute.Flag can appear in Create mode of commandFlag can have multiple arguments, passed either as a tuple or a list. |
|||
shortNames (sn) | bool | ||
|
|||
typeId (id) | int | ||
|
|||
typeNames (tn) | bool | ||
|
Derived from mel command maya.cmds.blindDataType
Example:
import pymel.core as pm
# To create a new blind data typeId with a floating point attribute
pm.blindDataType( id=9001, dt='float', longDataName='bdFloat', shortDataName='bdf' )
# Result: u'blindDataTemplate1' #
# To create a Blind Data type with several attributes
pm.blindDataType( 'ruf', '-dt', 'float', '-longDataName', 'smoothness', '-shortDataName', 'smo', '-dt', 'int' id=9005, dt='float', longDataName='roughness', shortDataName='', longDataName='count', shortDataName='cnt' )
# To query if a type is already used
pm.blindDataType( 9001
# to query the type of a single attribute
'blindDataType', '-q', '-id', 9001, '-tn', '-ldn', 'smoothness', query=True, id=True )
# to get the types and names for all attributes
pm.blindDataType( 9001, '-tn', query=True, id=True )