ObjectUtilsBase
- class xrfeitoria.object.object_utils.ObjectUtilsBase[source]
Base class for object utils.
- classmethod get_bound_box(name: str) Tuple[float, float, float][source]
Get bounding box of the object.
- Parameters:
name (str) – Name of the object.
- Returns:
Vector – Bounding box of the object.
- classmethod get_dimensions(name: str) Tuple[float, float, float][source]
Get dimensions of the object.
- Parameters:
name (str) – Name of the object.
- Returns:
Vector – Dimensions of the object.
- classmethod get_location(name: str) Tuple[float, float, float][source]
Get location of the object.
- Parameters:
name (str) – Name of the object.
- Returns:
Vector – Location of the object.
- classmethod get_rotation(name: str) Tuple[float, float, float][source]
Get rotation of the object.
- Parameters:
name (str) – Name of the object.
- Returns:
Vector – Rotation of the object.
- classmethod get_scale(name: str) Tuple[float, float, float][source]
Get scale of the object.
- Parameters:
name (str) – Name of the object.
- Returns:
Vector – Scale of the object.
- classmethod get_transform(name: str) Tuple[List, List, List][source]
Get transform (location, rotation, scale) of the object.
- Parameters:
name (str) – Name of the object.
- Returns:
Transform – (location 3D vector, rotation 3D vector, scale 3D vector). location: Location of the object. unit: meters. rotation: Rotation of the object. unit: degrees. scale: Scale of the object.
- classmethod set_location(name: str, location: Tuple[float, float, float])[source]
Set location of the object.
- Parameters:
name (str) – Name of the object.
location (Vector) – Location of the object.
- classmethod set_name(name: str, new_name: str)[source]
Set a new name for the object.
- Parameters:
name (str) – Original name of the object.
new_name (str) – New name of the object.
- classmethod set_rotation(name: str, rotation: Tuple[float, float, float])[source]
Set rotation of the object.
- Parameters:
name (str) – Name of the object.
rotation (Vector) – Rotation of the object.
- classmethod set_scale(name, scale: Tuple[float, float, float])[source]
Set scale of the object.
- Parameters:
name (str) – Name of the object.
scale (Vector) – Scale of the object.
- classmethod set_transform(name: str, location: Tuple[float, float, float], rotation: Tuple[float, float, float], scale: Tuple[float, float, float])[source]
Set transform (location, rotation, scale) of the object.
- Parameters:
name (str) – Name of the object.
location (Vector) – Location of the object.
rotation (Vector) – Rotation of the object.
scale (Vector) – Scale of the object.