diff --git a/contour_layer.go b/contour_layer.go index a2b2ef0..081555f 100644 --- a/contour_layer.go +++ b/contour_layer.go @@ -1,7 +1,6 @@ package main import ( - "fmt" "math" "math/rand" "github.com/gen2brain/raylib-go/raylib" @@ -52,7 +51,6 @@ func (s *ContourLayer) AddActors(n, sourceWidth, sourceHeight int32) { func (s *ContourLayer) Update(ctx *RenderCtx) { s.AddActors(100, ctx.SourceWidth, ctx.SourceHeight) - fmt.Printf("num actors = %d\n", len(s.actors)) } func (s *ContourLayer) Draw(ctx *RenderCtx) { @@ -81,7 +79,6 @@ func (a *Actor) Draw() { rad := rl.Remap(v, 0, 1, 0, 3*math.Pi) nextPosition := rl.Vector2{X: a.position.X + a.stepSize*float32(math.Cos(float64(rad))), Y: a.position.Y + a.stepSize*float32(math.Sin(float64(rad)))} rl.DrawLineV(a.position, nextPosition, a.color) - //fmt.Printf("position %v -> nextPosition %v \n", a.position, nextPosition) a.position = nextPosition } diff --git a/sketch.go b/sketch.go index 07afa73..a7ccaa4 100644 --- a/sketch.go +++ b/sketch.go @@ -1,6 +1,7 @@ package main import ( + "fmt" "math" "github.com/gen2brain/raylib-go/raylib" ) @@ -145,6 +146,9 @@ func (s *Sketch) Draw(ctx *RenderCtx) { b = config.b } tint := rl.NewColor(r, g, b, config.a) + + fmt.Printf("rendering layer '%s' with config %v\n", instance.name, instance.config) + rl.DrawTexturePro(instance.texture.Texture, src, dst, rl.Vector2{}, 0, tint) } }