mirror of
https://github.com/orange-cpp/omath.git
synced 2026-08-08 05:52:07 +00:00
added even more missing nodiscard messages
This commit is contained in:
@@ -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,
|
||||
|
||||
Reference in New Issue
Block a user