From 86a42b7f2ccca9d7ba7f93ef1ae232883eb5a86d Mon Sep 17 00:00:00 2001 From: sumi Date: Sat, 10 Jan 2026 22:32:44 -0600 Subject: [PATCH] automated snapshot --- contour_layer.go | 3 +-- internal/graphics/graphics.go | 2 +- main.go | 5 +++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/contour_layer.go b/contour_layer.go index b8ce1aa..dfe8bc2 100644 --- a/contour_layer.go +++ b/contour_layer.go @@ -92,8 +92,7 @@ func (a *Actor) Draw(env *Env, g *sg.Graphics) { g.SetStrokeWeight(1.0) g.SetStroke(true) - c := a.color - c.A = 255 + g.SetStrokeColor(a.color) g.DrawLine(a.position, nextPosition) //rl.DrawLineV(a.position, nextPosition, a.color) a.position = nextPosition diff --git a/internal/graphics/graphics.go b/internal/graphics/graphics.go index 4d0d5d5..88feff2 100644 --- a/internal/graphics/graphics.go +++ b/internal/graphics/graphics.go @@ -283,7 +283,7 @@ var ( FlourescentColors = makeFlourescentColors() ) -func Clamp(c rl.Color, min uint8, max uint8) rl.Color { +func Clamp(c color.RGBA, min uint8, max uint8) rl.Color { return rl.NewColor( uint8(rl.Clamp(float32(c.R), float32(min), float32(max))), uint8(rl.Clamp(float32(c.G), float32(min), float32(max))), diff --git a/main.go b/main.go index e1b57a3..b0be754 100644 --- a/main.go +++ b/main.go @@ -2,6 +2,7 @@ package main import ( "flag" + "image/color" "fmt" "log" "math" @@ -121,7 +122,7 @@ func main() { &AdderField{ fields: []Field{ &ScaleField{scale: 3, field: imageField}, - &ScaleField{scale: 750, field: noiseField}, + &ScaleField{scale: 250, field: noiseField}, }, }, } @@ -137,8 +138,8 @@ func main() { sketch.AddColorLayer("background-black", rl.Black) //sketch.AddLayer("moses", imageLayer) sketch.AddLayer("field", &FieldLayer{field: field, loColor: rl.NewColor(0, 0, 0, 0), hiColor: fieldColor, dirty: true}) - actorColor := colorCycle.Next() + actorColor := color.RGBA { R: 39, G: 58, B: 59, A: 50 } fmt.Printf("actor color = %v\n", actorColor) hsv := rl.ColorToHSV(actorColor)