Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/excessive/cpml
Cirno's Perfect Math Library: Just about everything you need for 2D/3D games. Hopefully.
https://github.com/excessive/cpml
math
Last synced: about 13 hours ago
JSON representation
Cirno's Perfect Math Library: Just about everything you need for 2D/3D games. Hopefully.
- Host: GitHub
- URL: https://github.com/excessive/cpml
- Owner: excessive
- License: other
- Created: 2014-10-25T17:37:06.000Z (about 10 years ago)
- Default Branch: master
- Last Pushed: 2023-10-07T15:41:53.000Z (over 1 year ago)
- Last Synced: 2025-01-07T12:10:54.028Z (8 days ago)
- Topics: math
- Language: Lua
- Homepage: https://excessive.github.io/cpml/
- Size: 474 KB
- Stars: 308
- Watchers: 13
- Forks: 41
- Open Issues: 18
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
- awesome-love2d - Cirno's Perfect Math Library - Math/intersection library designed for games. (Math)
- awesome-defold - cpml
README
Cirno's Perfect Math Library
====![Build Status](https://github.com/excessive/cpml/actions/workflows/runtest.yml/badge.svg)
[![Coverage Status](https://coveralls.io/repos/github/excessive/cpml/badge.svg?branch=master)](https://coveralls.io/github/excessive/cpml?branch=master)Various useful bits of game math. 3D line intersections, ray casting, 2d/3d vectors, 4x4 matrices, quaternions, etc.
Intended to be used with LuaJIT and LÖVE (this is the backbone of LÖVE3D).
Online documentation can be found [here](http://excessive.github.io/cpml/) or you can generate them yourself using `ldoc -c doc/config.ld -o index .`
# Installation
Clone the repository and require it, or if you prefer luarocks: `$ luarocks install --server=http://luarocks.org/dev cpml`. Add `--tree=whatever` for a local install.# Versions
This library has a major compatibility break at version 1.0. Up to version 0.10, composition `a*b` means "apply b, then a" for quaternions and "apply a, then b" for matrices. Now as of version 1.0, the two are consistent and matrix `a*b` means "apply b, then a".