automated snapshot
This commit is contained in:
10
main.go
10
main.go
@@ -13,7 +13,7 @@ import (
|
|||||||
|
|
||||||
gui "github.com/gen2brain/raylib-go/raygui"
|
gui "github.com/gen2brain/raylib-go/raygui"
|
||||||
rl "github.com/gen2brain/raylib-go/raylib"
|
rl "github.com/gen2brain/raylib-go/raylib"
|
||||||
//"github.com/ojrac/opensimplex-go"
|
"github.com/ojrac/opensimplex-go"
|
||||||
)
|
)
|
||||||
|
|
||||||
func Bootstrap() *Env {
|
func Bootstrap() *Env {
|
||||||
@@ -99,12 +99,14 @@ func main() {
|
|||||||
|
|
||||||
env := Bootstrap()
|
env := Bootstrap()
|
||||||
|
|
||||||
|
rl.SetTraceLogLevel(rl.LogError)
|
||||||
|
|
||||||
// reproducable flourescent color cycle
|
// reproducable flourescent color cycle
|
||||||
colorCycle := sg.NewFixedColorCycle(sg.FlourescentColors).Shuffle(0)
|
colorCycle := sg.NewFixedColorCycle(sg.FlourescentColors).Shuffle(0)
|
||||||
|
|
||||||
rng := rand.New(rand.NewSource(env.Time.Unix()))
|
rng := rand.New(rand.NewSource(env.Time.Unix()))
|
||||||
//imageField := NewImageField("/home/d/Dropbox/art/data/david.png")
|
//imageField := NewImageField("/home/d/Dropbox/art/data/david.png")
|
||||||
//noiseField := &SimplexNoiseField{Noise: opensimplex.New32(env.Time.Unix())}
|
noiseField := &SimplexNoiseField{Noise: opensimplex.New32(env.Time.Unix())}
|
||||||
//imageField := NewImageField("/home/d/Dropbox/art/data/ramstatue.png")
|
//imageField := NewImageField("/home/d/Dropbox/art/data/ramstatue.png")
|
||||||
//imageField := NewImageField("/home/d/Dropbox/art/data/bassrockastro/Photo Dec 24 2025, 5 58 23 PM.jpg")
|
//imageField := NewImageField("/home/d/Dropbox/art/data/bassrockastro/Photo Dec 24 2025, 5 58 23 PM.jpg")
|
||||||
//imageField := NewImageField("/home/d/Dropbox/art/data/bassrockastro/andromeda.jpg")
|
//imageField := NewImageField("/home/d/Dropbox/art/data/bassrockastro/andromeda.jpg")
|
||||||
@@ -119,7 +121,7 @@ func main() {
|
|||||||
&AdderField{
|
&AdderField{
|
||||||
fields: []Field{
|
fields: []Field{
|
||||||
&ScaleField{scale: 3, field: imageField},
|
&ScaleField{scale: 3, field: imageField},
|
||||||
&ScaleField{scale: 150, field: &SinXYField{ }},
|
&ScaleField{scale: 250, field: noiseField},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
@@ -148,7 +150,7 @@ func main() {
|
|||||||
//NewColor(11, 35, 176, 50),
|
//NewColor(11, 35, 176, 50),
|
||||||
|
|
||||||
//r
|
//r
|
||||||
contourLayer := NewContourLayer(&sketch, rng, field, actorColor, -4*math.Pi, 4*math.Pi)
|
contourLayer := NewContourLayer(&sketch, rng, field, actorColor, -12*math.Pi, 12*math.Pi)
|
||||||
sketch.AddLayer("contours", contourLayer)
|
sketch.AddLayer("contours", contourLayer)
|
||||||
sketch.AddLayer("sierpinski-arrowhead", sierpinskiLayer)
|
sketch.AddLayer("sierpinski-arrowhead", sierpinskiLayer)
|
||||||
// aurora := NewImageLayer("/home/d/Dropbox/photos/Events/2025/Aurora/Photo Nov 11 2025, 9 52 03 PM.jpg")
|
// aurora := NewImageLayer("/home/d/Dropbox/photos/Events/2025/Aurora/Photo Nov 11 2025, 9 52 03 PM.jpg")
|
||||||
|
|||||||
@@ -172,7 +172,6 @@ func (s *Sketch) Draw(env *Env) {
|
|||||||
rl.GenTextureMipmaps(&s.composite.Texture)
|
rl.GenTextureMipmaps(&s.composite.Texture)
|
||||||
rl.SetTextureFilter(s.composite.Texture, rl.FilterTrilinear)
|
rl.SetTextureFilter(s.composite.Texture, rl.FilterTrilinear)
|
||||||
|
|
||||||
|
|
||||||
// render each layer onto the composite
|
// render each layer onto the composite
|
||||||
offscreen.BeginPremultiplyBlend()
|
offscreen.BeginPremultiplyBlend()
|
||||||
offscreen.BeginTexture(s.composite)
|
offscreen.BeginTexture(s.composite)
|
||||||
|
|||||||
Reference in New Issue
Block a user