From 3da09c493a11865ea54ae26c2a2dfab5c4970d22 Mon Sep 17 00:00:00 2001 From: Hajime Hoshi Date: Mon, 12 Feb 2018 18:18:32 +0900 Subject: [PATCH] affine: Remove ebiten.Monochrome usages --- colorm_test.go | 3 ++- examples/blocks/blocks/gamescene.go | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/colorm_test.go b/colorm_test.go index 70c69142c..c9eb54f51 100644 --- a/colorm_test.go +++ b/colorm_test.go @@ -131,7 +131,8 @@ func TestColorMMonochrome(t *testing.T) { {0.2990, 0.5870, 0.1140, 0, 0}, {0, 0, 0, 1, 0}, } - m := Monochrome() + m := ColorM{} + m.ChangeHSV(0, 0, 1) for i := 0; i < 4; i++ { for j := 0; j < 5; j++ { got := m.Element(i, j) diff --git a/examples/blocks/blocks/gamescene.go b/examples/blocks/blocks/gamescene.go index d50f598b4..15b809130 100644 --- a/examples/blocks/blocks/gamescene.go +++ b/examples/blocks/blocks/gamescene.go @@ -167,7 +167,8 @@ func (s *GameScene) drawBackground(r *ebiten.Image) { op.GeoM.Translate(ScreenWidth/2, ScreenHeight/2) a := 0.7 - m := ebiten.Monochrome() + m := ebiten.ColorM{} + m.ChangeHSV(0, 0, 1) m.Scale(a, a, a, a) op.ColorM.Scale(1-a, 1-a, 1-a, 1-a) op.ColorM.Add(m)