Merge: Noise generators: Perlin and interpolated
authorJean Privat <jean@pryen.org>
Tue, 10 Mar 2015 23:38:32 +0000 (06:38 +0700)
committerJean Privat <jean@pryen.org>
Tue, 10 Mar 2015 23:38:32 +0000 (06:38 +0700)
commitce979c8c10b618c7d5e4be0e3224f580d2db4fdf
treee411caa120fc25aa1b73891b5f0c054c8b6066ba
parentd66b06f17fddd8045368ba5f5b483915582cbd64
parent2b089f4836df9b447069a2055102eddb4761ae86
Merge: Noise generators: Perlin and interpolated

Intro the PerlinNoise generator and the underlying (but independent) InterpolatedNoise, with some related services.

The rosetta code Perlin noise example (in 3D) is for comparison to my implementation in `lib/noise.nit` in (2D). We do not get the expected result with this implementation, 0.13691995878400010 vs 0.13691995878400012. It may be an error in the implementation of `Float.to_precision`... this will require further investigation.

The optimized `SequenceRead::rand` is a bonus! it is not used in this PR.

Pull-Request: #1194
Reviewed-by: Jean Privat <jean@pryen.org>
Reviewed-by: Alexandre Terrasa <alexandre@moz-code.org>
Reviewed-by: Lucas Bajolet <r4pass@hotmail.com>