|
scimesh 0.3.2
Headless CPU-only 3D software renderer for scientific mesh visualization
|
Camera definition and helper functions for view setup. More...


Go to the source code of this file.
Classes | |
| struct | scimesh::Camera |
| A virtual camera that defines the viewpoint for rendering. More... | |
Namespaces | |
| namespace | scimesh |
Enumerations | |
| enum class | scimesh::ProjectionType { scimesh::ORTHOGRAPHIC , scimesh::PERSPECTIVE } |
| The type of 3D→2D projection used by the camera. More... | |
Functions | |
| float | scimesh::perp_extent_radius (const Vec3 &bmin, const Vec3 &bmax, const Vec3 ¢er, const Vec3 &dir, float fov_radians, float *out_dist=nullptr) |
| Compute the "perpendicular extent radius" of an axis-aligned bounding box relative to a view direction. | |
| float | scimesh::max_ortho_extent (const Vec3 &bmin, const Vec3 &bmax, const Vec3 ¢er, const Vec3 &dir) |
| Compute the maximum perpendicular extent of an AABB from a view ray (for orthographic projection framing). | |
| Camera | scimesh::camera_look_at (const Vec3 ¢er, float radius, const Vec3 &direction, const Vec3 &up, float fov_degrees, float margin=1.1f, ProjectionType projection=ProjectionType::PERSPECTIVE) |
| Create a camera that looks at a point from a given distance and direction. | |
| Camera | scimesh::camera_fit_scene (const Scene &scene, const Vec3 &direction, const Vec3 &up, float fov_degrees, float margin=1.1f, ProjectionType projection=ProjectionType::PERSPECTIVE) |
| Create a camera that automatically frames an entire Scene. | |
| Camera | scimesh::camera_fit_mesh (const Mesh &mesh, const Vec3 &direction, const Vec3 &up, float fov_degrees, float margin=1.1f, ProjectionType projection=ProjectionType::PERSPECTIVE) |
| Create a camera that automatically frames a single Mesh. | |
| Camera | scimesh::camera_orbit (const Camera &camera, const Vec3 &axis, float angle_degrees) |
| Orbit the camera around its look-at point. | |
Camera definition and helper functions for view setup.
The camera controls what part of the 3D scene is visible and how it is projected onto the 2D image. scimesh supports two projection types: perspective (realistic, with foreshortening) and orthographic (flat, no perspective, useful for technical diagrams).
Definition in file camera.h.