From 2cc9053e108a649a302f5ecf0306b682d820d4e1 Mon Sep 17 00:00:00 2001 From: Sam Anthony Date: Mon, 20 Jun 2022 18:26:58 -0230 Subject: use gio for ui --- app.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'app.go') diff --git a/app.go b/app.go index f0f5068..8e9d8bb 100644 --- a/app.go +++ b/app.go @@ -35,13 +35,13 @@ type App struct { FlowUnit mass.FlowRate Comp compressor.Compressor - CompImg image.Image + CompImg *image.NRGBA } func NewApp() (App, error) { a := App{ Displacement: 2 * volume.Litre, - VolumeUnit: volume.Litre, + VolumeUnit: volume.CubicCentimetre, Rpm: []int{2000}, @@ -91,7 +91,7 @@ func (a *App) SetCompressor(c compressor.Compressor) error { } b := j.Bounds() - m := image.NewRGBA(image.Rect(0, 0, b.Dx(), b.Dy())) + m := image.NewNRGBA(image.Rect(0, 0, b.Dx(), b.Dy())) draw.Draw(m, m.Bounds(), j, b.Min, draw.Src) a.Comp = c -- cgit v1.2.3