mal-math
is a comprehensive C++20 mathematics library, providing a suite of utilities and structures to handle various mathematical constructs in an efficient and user-friendly manner.
- Matrices, vectors and quaternions: Generic mathematicals structures, supporting different dimensions and primitive types.
- Efficiency: Highly optimized functions using modern C++ features.
- Extensibility: Built with modularity in mind, making it easier to extend or adapt to specific needs.
- Doxygen Comments: Comprehensive Doxygen documentation for all classes, functions, and members, enabling automatic generation of detailed documentation.
- Downsides: Doesn't have SIMD(Uyet).
- Clone the repository:
git clone https://github.com/malatindez/math
Here's a basic example on how to use the vec
structure:
#include "mal-math/vec.hpp"
int main() {
mal_math::vec3 v1(1.0f, 2.0f, 3.0f);
mal_math::vec3 v2(2.0f, 3.0f, 4.0f);
mal_math::mat3 m1(v1, v2, 3,4,5);
mal_math::mat3 m2(v1, v1, v1);
auto result_v = v1 + v2;
auto result_m = m1 + m2;
std::cout << result_v; //
std::cout << result_m; // operator<< is overloaded as well
// Do more stuff...
return 0;
}
The documentation is available @ malatindez.github.io/math
- Fork the repository.
- Create your feature branch:
git checkout -b feature/my-new-feature
- Commit your changes:
git commit -m "Add my new feature"
- Push to the branch:
git push origin feature/my-new-feature
- Submit a pull request.
This project is licensed under the MIT License - see the LICENSE file for details.