2018-09-20 16:50:34 +08:00
|
|
|
[package]
|
|
|
|
name = "nalgebra-glm"
|
2018-10-22 21:39:53 +08:00
|
|
|
version = "0.2.0"
|
2018-09-20 16:50:34 +08:00
|
|
|
authors = ["sebcrozet <developer@crozet.re>"]
|
|
|
|
|
2018-09-23 23:14:30 +08:00
|
|
|
description = "A computer-graphics oriented API for nalgebra, inspired by the C++ GLM library."
|
|
|
|
documentation = "https://www.nalgebra.org/rustdoc_glm/nalgebra_glm/index.html"
|
|
|
|
homepage = "https://nalgebra.org"
|
|
|
|
repository = "https://github.com/rustsim/nalgebra"
|
|
|
|
readme = "../README.md"
|
|
|
|
categories = [ "science" ]
|
|
|
|
keywords = [ "linear", "algebra", "matrix", "vector", "math" ]
|
|
|
|
license = "BSD-3-Clause"
|
|
|
|
|
2018-12-14 13:24:18 +08:00
|
|
|
[features]
|
|
|
|
|
2018-12-14 20:11:49 +08:00
|
|
|
## Default to produce opengl compatible matrices and conventions
|
2018-12-14 13:24:18 +08:00
|
|
|
default = ["opengl_projection"]
|
|
|
|
|
2018-12-14 20:11:49 +08:00
|
|
|
## Produce projection matrices and default to coordinate space behaviour that is compatible with OpenGL's NDC space
|
2018-12-14 13:24:18 +08:00
|
|
|
opengl_projection = ["right_hand_default", "negone_to_one_clip_default"]
|
2018-12-14 20:11:49 +08:00
|
|
|
|
|
|
|
## Produce projection matrices and default to coordinate space behaviour that is compatible with Vulkan's NDC space
|
2018-12-14 13:24:18 +08:00
|
|
|
vulkan_projection = ["right_hand_default", "zero_to_one_clip_default", "projection_y_flip"]
|
2018-12-14 20:11:49 +08:00
|
|
|
|
|
|
|
## Produce projection matrices and default to coordinate space behaviour that is compatible with DirectX's NDC space
|
2018-12-14 13:24:18 +08:00
|
|
|
directx_projection = ["left_hand_default", "zero_to_one_clip_default"]
|
|
|
|
|
2018-12-14 20:11:49 +08:00
|
|
|
## Applies an implicit `mat[(1,1)] *= -1` to all projection matrices. Essentially flips the output of using the matrix
|
|
|
|
## about the x axis (vertical flip)
|
2018-12-14 13:24:18 +08:00
|
|
|
projection_y_flip = []
|
|
|
|
|
2018-12-14 20:11:49 +08:00
|
|
|
## Whether to default to left hand (DirectX) or right hand (OpenGL/Vulkan) coordinate system behaviour
|
2018-12-14 13:24:18 +08:00
|
|
|
left_hand_default = []
|
|
|
|
right_hand_default = []
|
|
|
|
|
2018-12-14 20:11:49 +08:00
|
|
|
## Whether to default to 0 to 1 depth range (DirectX, Vulkan, Metal) or -1 to 1 (OpenGL) behaviour
|
2018-12-14 13:24:18 +08:00
|
|
|
zero_to_one_clip_default = []
|
|
|
|
negone_to_one_clip_default = []
|
|
|
|
|
2018-09-20 16:50:34 +08:00
|
|
|
[dependencies]
|
|
|
|
num-traits = { version = "0.2", default-features = false }
|
2018-09-20 20:23:31 +08:00
|
|
|
approx = { version = "0.3", default-features = false }
|
2018-09-20 16:50:34 +08:00
|
|
|
alga = "0.7"
|
2018-10-05 12:09:08 +08:00
|
|
|
nalgebra = { path = "..", version = "^0.16.4" }
|