9 Commits
3.2 ... 3.4

Author SHA1 Message Date
ebfc15d8af Prepare 3.4. 2020-05-21 20:11:36 +02:00
5b92d7b715 Merge pull request #43 from phaazon/dependabot/cargo/master/float-cmp-0.8
Update float-cmp requirement from 0.6 to 0.8
2020-05-21 20:04:34 +02:00
8f7cc9e711 Bump float-cmp upper bound to accept float-cmp-0.8. 2020-05-21 19:59:48 +02:00
9d930d6f16 Update float-cmp requirement from 0.6 to 0.8
Updates the requirements on [float-cmp](https://github.com/mikedilger/float-cmp) to permit the latest version.
- [Release notes](https://github.com/mikedilger/float-cmp/releases)
- [Commits](https://github.com/mikedilger/float-cmp/commits)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-05-04 22:42:05 +00:00
0afebc3319 Synchronize README. 2020-04-29 03:27:10 +02:00
4a2f349954 Prepare 3.3.0. 2020-04-09 23:51:07 +02:00
85ac489636 Add the dependabot setup. 2020-04-09 22:39:50 +02:00
aea9011296 Merge pull request #41 from alexbool/update-nalgebra-0.21
bump nalgebra
2020-04-09 22:15:50 +02:00
04247d8706 bump nalgebra 2020-04-06 17:17:40 +03:00
5 changed files with 39 additions and 14 deletions

12
.dependabot/config.yml Normal file
View File

@ -0,0 +1,12 @@
version: 1
update_configs:
- package_manager: "rust:cargo"
directory: "."
update_schedule: "live"
target_branch: "master"
default_reviewers:
- "phaazon"
default_assignees:
- "phaazon"
default_labels:
- "dependency-update"

View File

@ -1,17 +1,30 @@
# 3.4
> Thu May 21st 2020
- Add support for `float-cmp-0.7` and `float-cmp-0.8`. Because this uses a SemVer range, if you
already have a `Cargo.lock`, dont forget to update `splines` with `cargo update --aggressive`.
# 3.3
> Thu Apr 10th 2020
- Add support for `nalgebra-0.21`.
# 3.2
> Thu Mar 19th 2020
> Thu Mar 19th 2020
- Add support for `nalgebra-0.20`.
- Add support for `float-cmp-0.6`.
# 3.1.0
# 3.1
> Sat Jan 26th 2020
- Add support for `nalgebra-0.19`.
# 3.0.0
# 3.0
> Tue Oct 22th 2019
@ -24,7 +37,7 @@
- Fix Bézier interpolation when the next key is Bézier too.
# 2.2.0
# 2.2
> Mon Oct 17th 2019
@ -52,7 +65,7 @@
- Fix the cubic Bézier curve interpolation. The “output” tangent is now taken by mirroring the
next keys tangent around its control point.
# 2.0.0
# 2.0
> Mon Sep 23rd 2019

View File

@ -1,6 +1,6 @@
[package]
name = "splines"
version = "3.2.0"
version = "3.4.0"
license = "BSD-3-Clause"
authors = ["Dimitri Sabadie <dimitri.sabadie@gmail.com>"]
description = "Spline interpolation made easy"
@ -22,20 +22,20 @@ maintenance = { status = "actively-developed" }
[features]
default = ["std"]
impl-cgmath = ["cgmath"]
impl-nalgebra = ["alga", "nalgebra", "num-traits"]
impl-nalgebra = ["nalgebra", "num-traits", "simba"]
serialization = ["serde", "serde_derive"]
std = []
[dependencies]
alga = { version = "0.9", optional = true }
cgmath = { version = "0.17", optional = true }
nalgebra = { version = "0.20", optional = true }
nalgebra = { version = "0.21", optional = true }
num-traits = { version = "0.2", optional = true }
serde = { version = "1", optional = true }
serde_derive = { version = "1", optional = true }
simba = { version = "0.1.2", optional = true }
[dev-dependencies]
float-cmp = "0.6"
float-cmp = ">=0.6, < 0.9"
serde_json = "1"
[package.metadata.docs.rs]

View File

@ -24,7 +24,7 @@ is picked from its lower control point.
# Quickly create splines
```
```rust
use splines::{Interpolation, Key, Spline};
let start = Key::new(0., 0., Interpolation::Linear);
@ -46,7 +46,7 @@ value.
If you try to sample in out-of-bounds sampling parameter, youll get no value.
```
```rust
assert_eq!(spline.sample(0.), Some(0.));
assert_eq!(spline.clamped_sample(1.), Some(10.));
assert_eq!(spline.sample(1.1), None);
@ -56,7 +56,7 @@ Its possible that you want to get a value even if youre out-of-bounds. Thi
important for simulations / animations. Feel free to use the `Spline::clamped_interpolation` for
that purpose.
```
```rust
assert_eq!(spline.clamped_sample(-0.9), Some(0.)); // clamped to the first key
assert_eq!(spline.clamped_sample(1.1), Some(10.)); // clamped to the last key
```

View File

@ -1,6 +1,6 @@
use alga::general::{ClosedAdd, ClosedDiv, ClosedMul, ClosedSub};
use nalgebra::{Scalar, Vector, Vector1, Vector2, Vector3, Vector4, Vector5, Vector6};
use num_traits as nt;
use simba::scalar::{ClosedAdd, ClosedDiv, ClosedMul, ClosedSub};
use std::ops::Mul;
use crate::interpolate::{