From 08beed430618dece14dcabc9c7bd36e62afa098b Mon Sep 17 00:00:00 2001 From: Hajime Hoshi Date: Wed, 14 Mar 2018 12:11:11 +0900 Subject: [PATCH] examples/keyboard: Use image.Decode instead of png.Decode --- examples/keyboard/main.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/examples/keyboard/main.go b/examples/keyboard/main.go index 2eb4360d2..1058df200 100644 --- a/examples/keyboard/main.go +++ b/examples/keyboard/main.go @@ -18,7 +18,8 @@ package main import ( "bytes" - "image/png" + "image" + _ "image/png" "log" "strconv" @@ -35,7 +36,7 @@ const ( var keyboardImage *ebiten.Image func init() { - img, err := png.Decode(bytes.NewReader(rkeyabord.Keyboard_png)) + img, _, err := image.Decode(bytes.NewReader(rkeyabord.Keyboard_png)) if err != nil { log.Fatal(err) }