Simplex
Extends Noise
Generates simplex-based noise.
This is a modified version of the freely published version in the paper by Stefan Gustavson at http://staffwww.itn.liu.se/~stegu/simplexnoise/simplexnoise.pdf
Constants
F2 protected
php
protected const F2 = 0.5 * (\M_SQRT3 - 1)F3 protected
php
protected const F3 = 1.0 / 3.0G2 protected
php
protected const G2 = (3 - \M_SQRT3) / 6G22 protected
php
protected const G22 = self::G2 * 2.0 - 1G3 protected
php
protected const G3 = 1.0 / 6.0grad3 protected
php
protected const grad3 = [[1, 1, 0], [-1, 1, 0], [1, -1, 0], [-1, -1, 0], [1, 0, 1], [-1, 0, 1], [1, 0, -1], [-1, 0, -1], [0, 1, 1], [0, -1, 1], [0, 1, -1], [0, -1, -1]]Properties
$offsetX protected
php
protected float $offsetX$offsetY protected
php
protected float $offsetY$offsetZ protected
php
protected float $offsetZ$perm protected
php
protected array $permMethods
__construct()
php
public function __construct(\pocketmine\utils\Random $random, int $octaves, float $persistence, float $expansion)getNoise2D()
php
public function getNoise2D($x, $y)getNoise3D()
php
public function getNoise3D($x, $y, $z)