CameraContext

Inheritance diagram of rumba.CameraContext
class CameraContext

Bases: pybind11_builtins.pybind11_object

This class provides viewport space conversion services.

This interface is passed to the viewport events and is implemented by the application.

Methods

camera_to_world() Return the camera to world matrix of the event’s viewport.
depth() Returns the depth of the pixel which have been hit during the event.
pixel_to_world(screen_pos) Convert viewport pixel coordinates and depth in world space position.
world_to_pixel(world_pos) Convert world space position in viewport pixel coordinates and depth.
__init__

x.__init__(…) initializes x; see help(type(x)) for signature

camera_to_world() → Imath.M44f

Return the camera to world matrix of the event’s viewport.

Return type:Imath.M44f
depth() → float

Returns the depth of the pixel which have been hit during the event.

Return type:float
pixel_to_world(screen_pos: Imath.V2i, depth: float) → Imath.V3f

Convert viewport pixel coordinates and depth in world space position.

Return type:Imath.V3f
world_to_pixel(world_pos: Imath.V3f) → Imath.V3f

Convert world space position in viewport pixel coordinates and depth.

Return type:Imath.V3f