23 lines
480 B
Go
23 lines
480 B
Go
package main
|
|
|
|
import (
|
|
"github.com/jdxyw/generativeart"
|
|
"github.com/jdxyw/generativeart/arts"
|
|
"github.com/jdxyw/generativeart/common"
|
|
"image/color"
|
|
"math/rand"
|
|
"time"
|
|
)
|
|
|
|
func main() {
|
|
rand.Seed(time.Now().Unix())
|
|
c := generativeart.NewCanva(2080, 2080)
|
|
c.SetBackground(color.RGBA{230, 230, 230, 255})
|
|
c.SetLineWidth(10)
|
|
c.SetIterations(15000)
|
|
c.SetColorSchema(common.DarkPink)
|
|
c.FillBackground()
|
|
c.Draw(arts.NewDotLine(100, 20, 50, false))
|
|
c.ToPNG("dotline.png")
|
|
}
|