Versions in this module Expand all Collapse all v1 v1.0.0 Aug 27, 2016 Changes in this version + type Builder2D struct + Bounds Builder2DBounds + Height int + Source NoiseyGet2D + Values []float64 + Width int + func NewBuilder2D(s NoiseyGet2D, width int, height int) (b Builder2D) + func (b *Builder2D) Build() + func (b *Builder2D) GetMinMax() (min float64, max float64) + type Builder2DBounds struct + MaxX float64 + MaxY float64 + MinX float64 + MinY float64 + type FBMGenerator2D struct + Frequency float64 + Lacunarity float64 + NoiseMaker NoiseyGet2D + Octaves int + Persistence float64 + func NewFBMGenerator2D(noise NoiseyGet2D, octaves int, persistence float64, lacunarity float64, ...) (fbm FBMGenerator2D) + func (fbm *FBMGenerator2D) Get2D(x float64, y float64) (v float64) + type FBMGenerator3D struct + Frequency float64 + Lacunarity float64 + NoiseMaker NoiseyGet3D + Octaves int + Persistence float64 + func NewFBMGenerator3D(noise NoiseyGet3D, octaves int, persistence float64, lacunarity float64, ...) (fbm FBMGenerator3D) + func (fbm *FBMGenerator3D) Get3D(x float64, y float64, z float64) (v float64) + type GeneratorJSON struct + Bias float64 + EdgeFalloff float64 + Frequency float64 + GeneratorType string + Generators []string + Lacunarity float64 + LowerBound float64 + Max float64 + Min float64 + Name string + Octaves int + Persistence float64 + Scale float64 + Sources []string + UpperBound float64 + type NoiseJSON struct + Generators []GeneratorJSON + Seeds map[string]int64 + Sources map[string]SourceJSON + func LoadNoiseJSON(bytes []byte) (*NoiseJSON, error) + func NewNoiseJSON() *NoiseJSON + func (cfg *NoiseJSON) BuildGenerators() error + func (cfg *NoiseJSON) BuildSources(seedBuilder RandomSeedBuilder) error + func (cfg *NoiseJSON) GetGenerator(name string) NoiseyGet2D + func (cfg *NoiseJSON) SaveNoiseJSON() ([]byte, error) + type NoiseyGet2D interface + Get2D func(float64, float64) float64 + type NoiseyGet3D interface + Get3D func(float64, float64, float64) float64 + type OpenSimplexGenerator struct + PermGradIndex3D []int + Permutations []int + Rng RandomSource + func NewOpenSimplexGenerator(rng RandomSource) (osg OpenSimplexGenerator) + func (osg *OpenSimplexGenerator) Get2D(x float64, y float64) float64 + func (osg *OpenSimplexGenerator) Get3D(x float64, y float64, z float64) float64 + type PerlinGenerator struct + Permutations []int + RandomGradients []Vec4f + Rng RandomSource + func NewPerlinGenerator(rng RandomSource) (pg PerlinGenerator) + func (pg *PerlinGenerator) Get2D(x, y float64) float64 + func (pg *PerlinGenerator) Get3D(x, y, z float64) float64 + type RandomSeedBuilder func(s int64) RandomSource + type RandomSource interface + Float64 func() float64 + Perm func(int) []int + type Scale2D struct + Bias float64 + Max float64 + Min float64 + Scale float64 + Source NoiseyGet2D + func NewScale2D(src NoiseyGet2D, scale float64, bias float64, min float64, max float64) (scales Scale2D) + func (scales *Scale2D) Get2D(x float64, y float64) (v float64) + type Select2D struct + Control NoiseyGet2D + EdgeFalloff float64 + LowerBound float64 + SourceA NoiseyGet2D + SourceB NoiseyGet2D + UpperBound float64 + func NewSelect2D(a, b, c NoiseyGet2D, lower float64, upper float64, edge float64) (selector Select2D) + func (selector *Select2D) Get2D(x float64, y float64) (v float64) + type Select3D struct + Control NoiseyGet3D + EdgeFalloff float64 + LowerBound float64 + SourceA NoiseyGet3D + SourceB NoiseyGet3D + UpperBound float64 + func NewSelect3D(a, b, c NoiseyGet3D, lower float64, upper float64, edge float64) (selector Select3D) + func (selector *Select3D) Get3D(x, y, z float64) (v float64) + type SourceJSON struct + Seed string + SourceType string + type Vec2f struct + X float64 + Y float64 + type Vec2i struct + X int + Y int + type Vec3f struct + X float64 + Y float64 + Z float64 + type Vec3i struct + X int + Y int + Z int + type Vec4f struct + W float64 + X float64 + Y float64 + Z float64