BindMaterialCommand
- class omni.usd.commands.BindMaterialCommand(prim_path: Union[str, list], material_path: str, strength=None, stage: Optional[Stage] = None, context_name: Optional[str] = None, material_purpose: Optional[str] = '')
Bases:
Command
,UsdStageHelper
Bind material to a primitive.
Methods
__init__
(prim_path, material_path[, ...])Constructor.
do
()undo
()- __init__(prim_path: Union[str, list], material_path: str, strength=None, stage: Optional[Stage] = None, context_name: Optional[str] = None, material_purpose: Optional[str] = '')
Constructor.
- Parameters
prim_path (str or list) – Path(s) to prim or collection
material_path (str) – Path to material to bind.
strength (float, optional) – Strength. Default is None, which sets the strength value from setting /persistent/app/stage/materialStrength. If no setting is set, it’s set to UsdShade.Tokens.weakerThanDescendants.
stage (Usd.Stage, optional) – Stage to operate. Default is None, which means the stage in the default UsdContext is used.
context_name (str, optional) – The usd context to operate. Default is None, which means the default UsdContext is used.
material_purpose (str, optional) – Material purpose. Default is UsdShade.Tokens.allPurpose.
- class PathType(value)
Bases:
Enum
An enumeration.