newton.usd.get_attribute#

newton.usd.get_attribute(prim: Prim, name: str, default: None = None) Any | None[source]#
newton.usd.get_attribute(prim: Prim, name: str, default: Any) Any

Get an attribute value from a USD prim, returning a default if not found.

Parameters:
  • prim – The USD prim to query.

  • name – The name of the attribute to retrieve.

  • default – The default value to return if the attribute is not found or invalid.

Returns:

The attribute value if it exists and is valid, otherwise the default value.