Fixes a potential type conversion issue by explicitly casting the x-coordinate to float in the world_to_screen test. This prevents possible compiler warnings and ensures the intended behavior.
Adds a test to verify the consistency of world-to-screen and
screen-to-world projections. This ensures that projecting a point
from world to screen and back results in the same point, thereby
validating the correctness of the camera projection transformations.
Adds functionality to convert screen coordinates to world space, including handling for cases where the inverse view projection matrix is singular or when the world position is out of screen bounds.
Also exposes Camera class to unit tests.
Adds an angle class with support for different normalization
and clamping strategies. Includes trigonometric functions and
arithmetic operators. Introduces unit tests to verify correct
functionality.
Disables unity builds to address a compilation issue.
Removes the deprecated `Matrix` class and its associated source files and unit tests.
This change is to ensure code cleanliness and prevent accidental usage of the slow and outdated `Matrix` class.
The `Mat` class should be used instead.
Moves linear algebra headers to a new subdirectory to improve project structure.
Updates includes to reflect the directory change.
Adds vcpkg to the tracked repositories.
Adds `std::formatter` specializations for `Mat`, `Vector2`, `Vector3`, and `Vector4` types, enabling the use of `std::format` for these types.
This simplifies formatting and printing of these mathematical objects, improving code readability and consistency.
Also adds a hash function specialization for Vector3.
The view angle rotation matrix order in Unreal Engine was incorrect, leading to incorrect camera orientation.
This commit fixes the order of rotation matrices to roll, pitch, yaw
to correctly implement Unreal Engine camera rotations.
Adds comprehensive unit tests for Unreal Engine formulas, camera and constants.
Marks Unreal Engine as supported in README.md.
Adds Unreal Engine-specific implementations for camera and projectile prediction calculations.
This includes:
- Defining constants and data types tailored for Unreal Engine's coordinate system and conventions.
- Implementing functions for calculating forward, right, and up vectors, view matrices, and perspective projection matrices.
- Providing camera trait for look-at angle calculations and projection matrix generation.
- Implements projectile prediction traits and utilities.
Updates unit tests to include more accurate assertions for camera projections.
Adds .idea/workspace.xml to .gitignore to prevent tracking local IDE settings.
Refactors some test fixture class names for consistency.
Adds project-specific IDE settings to improve code style consistency and development environment.
Removes the .idea directory from the .gitignore file, as these files are now intended to be part of the project for consistent IDE configuration across contributors.
Adds less than, greater than, less than or equal, and greater than or equal operators to the Vector2, Vector3 and Vector4 classes.
The comparison is based on the lengths of the vectors.
Adds corresponding unit tests.
The changes encapsulate the matrix tests within an `#ifdef` block, allowing conditional compilation based on whether `OMATH_ENABLE_LEGACY` is defined. This enables the legacy code to be compiled only when needed.
Updates the CMakeLists.txt to use the project name as the library target name instead of hardcoding "omath".
This change ensures consistency and avoids potential conflicts when integrating the library into other projects.
It also aligns the target naming with CMake best practices.