FramePrimsCommand

class omni.usd.commands.FramePrimsCommand(prim_to_move: Union[str, Path], prims_to_frame: Optional[Sequence[Union[str, Path]]] = None, time_code: Optional[TimeCode] = None, usd_context_name: str = '', aspect_ratio: float = 1, use_horizontal_fov: Optional[bool] = None, zoom: float = 0.45, horizontal_fov: float = 0.20656116130367255)

Bases: Command

Transform a primitive to encompass the bounds of a list of paths.

Parameters
  • prim_to_move – Path to the primitive that is being moved.

  • prims_to_frame (Sequence[Union[str, Sdf.Path]]) – Sequence of primitives to use to calculate the bounds to frame.

  • time_code (Usd.TimeCode) – Timecode to set values at.

  • usd_context_name (str) – Name of the usd context to work on.

  • aspect_ratio (float) – Width / Height of the final image.

  • use_horizontal_fov (bool) – Whether to use a camera’s horizontal or vertical field of view for framing.

  • horizontal_fov (float) – Default horizontal field-of-view to use for framing if one cannot be calculated.

  • zoom (float) – Final zoom in or out of the framed box. Values above 0.5 move further away and below 0.5 go closer.

Methods

__init__(prim_to_move[, prims_to_frame, ...])

do()

undo()

__init__(prim_to_move: Union[str, Path], prims_to_frame: Optional[Sequence[Union[str, Path]]] = None, time_code: Optional[TimeCode] = None, usd_context_name: str = '', aspect_ratio: float = 1, use_horizontal_fov: Optional[bool] = None, zoom: float = 0.45, horizontal_fov: float = 0.20656116130367255)