ebitenutil: Remove go-bindata usage and use file2byteslice

Fixes #499
This commit is contained in:
Hajime Hoshi 2018-02-09 02:46:33 +09:00
parent 8f8b37066b
commit eb2f3cf4f9
2 changed files with 133 additions and 208 deletions

View File

@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:generate go-bindata -nocompress -pkg=assets text.png //go:generate file2byteslice -input text.png -output bindata.go -package assets -var textPng
//go:generate gofmt -s -w . //go:generate gofmt -s -w .
package assets package assets
@ -32,8 +32,7 @@ const (
) )
func TextImage() image.Image { func TextImage() image.Image {
b := MustAsset("text.png") img, _, err := image.Decode(bytes.NewBuffer(textPng))
img, _, err := image.Decode(bytes.NewBuffer(b))
if err != nil { if err != nil {
panic(fmt.Sprintf("assets: image.Decode failed, %v", err)) panic(fmt.Sprintf("assets: image.Decode failed, %v", err))
} }

File diff suppressed because one or more lines are too long