Correlation 4.10.0
An Analysis Tool for Liquids and for Amorphous Solids
Loading...
Searching...
No Matches
RayPicker.cpp File Reference

Implementation of ray-sphere atom picking and camera HUD projection utilities. More...

#include "render3d/RayPicker.hpp"
#include <algorithm>
#include <array>
#include <cmath>
#include <format>
#include <limits>
#include <numbers>
Include dependency graph for RayPicker.cpp:

Namespaces

namespace  correlation
namespace  correlation::render3d

Functions

std::optional< std::size_t > correlation::render3d::pickAtom (const Camera3D &camera, const Scene3D &scene, float norm_x, float norm_y) noexcept
 Picks the closest visible atom sphere intersected by a viewport click ray.
CameraHudMetrics correlation::render3d::computeCameraHudMetrics (const Camera3D &camera, float viewport_height_px)
 Computes projected axis triad vectors and a nice-number Angstrom scale bar.

Detailed Description

Implementation of ray-sphere atom picking and camera HUD projection utilities.

License
SPDX-License-Identifier: AGPL-3.0-only