added even more missing nodiscard messages

This commit is contained in:
2026-06-15 20:31:57 +03:00
parent 2779bae82f
commit fee4e4b9e3
24 changed files with 88 additions and 80 deletions
@@ -12,7 +12,7 @@ namespace omath::source_engine
class CameraTrait final
{
public:
[[nodiscard]]
[[nodiscard("look-at angle result should not be discarded")]]
constexpr static ViewAngles calc_look_at_angle(const Vector3<float>& cam_origin,
const Vector3<float>& look_at) noexcept
{
@@ -22,12 +22,12 @@ namespace omath::source_engine
YawAngle::from_radians(internal::atan2(direction.y, direction.x)), RollAngle::from_radians(0.f)};
}
[[nodiscard]]
[[nodiscard("view matrix result should not be discarded")]]
constexpr static Mat4X4 calc_view_matrix(const ViewAngles& angles, const Vector3<float>& cam_origin) noexcept
{
return source_engine::calc_view_matrix(angles, cam_origin);
}
[[nodiscard]]
[[nodiscard("projection matrix result should not be discarded")]]
constexpr static Mat4X4 calc_projection_matrix(const projection::FieldOfView& fov,
const projection::ViewPort& view_port, const float near_plane,
const float far_plane,