shamrock.math.Camera3d_f64_3#
- class shamrock.math.Camera3d_f64_3#
Bases:
pybind11_objectPerspective camera following the OpenGL conventions (gluLookAt + gluPerspective).
Pixel
(ix, iy)coversixfrom left to right andiyfrom bottom to top, its ray goes through the pixel center, starts on the near plane and extends to infinity, so that nothing behind the image plane is rendered.Methods
Camera with ny = round(nx / aspect), fovy being the vertical field of view in radians
Rays of all the pixels, pixel (ix, iy) being at index iy * nx + ix
Camera at pos looking at target (gluLookAt convention), fovy being the vertical field of view in radians
- static from_aspect(pos: f64_3, dir: f64_3, up: f64_3, nx: int, aspect: float, fovy: float, znear: float, zfar: float) shamrock.pyshamrock.math.Camera3d_f64_3#
Camera with ny = round(nx / aspect), fovy being the vertical field of view in radians
- get_camera_transform(self: shamrock.pyshamrock.math.Camera3d_f64_3) shammath::mat<double, 4, 4>#
- get_camera_transform_inv(self: shamrock.pyshamrock.math.Camera3d_f64_3) shammath::mat<double, 4, 4>#
- get_dir(self: shamrock.pyshamrock.math.Camera3d_f64_3) f64_3#
- get_pixel_ray(self: shamrock.pyshamrock.math.Camera3d_f64_3, ix: int, iy: int) shamrock.pyshamrock.math.Ray_f64_3#
- get_pos(self: shamrock.pyshamrock.math.Camera3d_f64_3) f64_3#
- get_projection_matrix(self: shamrock.pyshamrock.math.Camera3d_f64_3) shammath::mat<double, 4, 4>#
- get_projection_matrix_inv(self: shamrock.pyshamrock.math.Camera3d_f64_3) shammath::mat<double, 4, 4>#
- get_rays(self: shamrock.pyshamrock.math.Camera3d_f64_3) list[shamrock.pyshamrock.math.Ray_f64_3]#
Rays of all the pixels, pixel (ix, iy) being at index iy * nx + ix
- get_right(self: shamrock.pyshamrock.math.Camera3d_f64_3) f64_3#
- get_up(self: shamrock.pyshamrock.math.Camera3d_f64_3) f64_3#
- get_view_matrix(self: shamrock.pyshamrock.math.Camera3d_f64_3) shammath::mat<double, 4, 4>#
- get_view_matrix_inv(self: shamrock.pyshamrock.math.Camera3d_f64_3) shammath::mat<double, 4, 4>#