Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
Mats
Mats is a matrix math library written in Rust, designed to provide lightweight, efficient, and easy-to-use matrix types and algorithms. It includes commonly used matrix algorithm encapsulation in fields such as linear algebra and computer graphics.
Features
uniforms: If this feature is enabled,Matswill implement traitAsUniformValuefor specific types of matrices, allowing them to interact with OpenGL.graphics: If this feature is enabled,Matswill provide tools for computer graphics, such as coordinate transformation matrices.
Example
use Mat2;
License
Licensed under either of MIT license or Apache License, Version 2.0 at your option.
Release Notes
Release v2.0.1
Fix
- Add attribute
#[inline]to a simple function. - Revise the implementation of trait
Indexfor typeMat. - Supplement the implementation of trait
IndexMutfor typeMat.
Release v2.0.0
Features
A vector is a matrix with only one column. The matrix is column-major
-
Matrix:
- Addition, subtraction, multiplication, division and their assignment of matrices.
- Transposition of matrices.
- Dot product of matrices.
- Cross product of 3D vectors.
- Like GLSL vector member access syntax.
- Vector types alias.
-
GLSL Data Interface(with feature
uniforms):- Implement trait
AsUniformValue(from crateglium) for specific matrix types.
- Implement trait
-
Computer Graphics(with feature
graphics):- If feature
graphicsis enabled, the featureuniformsis also enabled automatically.
- Coorinate transformations:
- 2D/3D: Translation, rotation, scaling.
- Projection: Orthographic, perspective.
- Viewport transformation.
- If feature
Before v2.0.0
This crate was originally born to solidify my Rust programming skills. Later, I tried some OpenGL tools and added matrix algorithms used in OpenGL to it. I think it could be more complete. So, starting from v2.0.0, I plan to refactor it based on my understanding of Rust updates, and make it a great choice for content related to matrix algorithms in Rust!
Futures
I plan to refactor the project in the future to make it easier to use and maintain. In version 2.0.0, I will prioritize basic matrix operations and some basic operations, as well as parts related to computer graphics. More content related to linear algebra, as well as matrix calculations such as robot kinematics, robot inverse kinematics, and neural networks, will be added in the future.