mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2024-12-24 18:58:54 +01:00
ebitenutil: Refactoring: Remove debugPrintRenderTarget
This commit is contained in:
parent
adbd0db765
commit
deed56f971
@ -24,8 +24,7 @@ import (
|
||||
)
|
||||
|
||||
type debugPrintState struct {
|
||||
textImage *ebiten.Image
|
||||
debugPrintRenderTarget *ebiten.Image
|
||||
textImage *ebiten.Image
|
||||
}
|
||||
|
||||
var defaultDebugPrintState = &debugPrintState{}
|
||||
@ -86,10 +85,6 @@ func (d *debugPrintState) DebugPrint(r *ebiten.Image, str string) {
|
||||
img := assets.CreateTextImage()
|
||||
d.textImage, _ = ebiten.NewImageFromImage(img, ebiten.FilterNearest)
|
||||
}
|
||||
if d.debugPrintRenderTarget == nil {
|
||||
width, height := 256, 256
|
||||
d.debugPrintRenderTarget, _ = ebiten.NewImage(width, height, ebiten.FilterNearest)
|
||||
}
|
||||
d.drawText(r, str, 1, 1, color.NRGBA{0x00, 0x00, 0x00, 0x80})
|
||||
d.drawText(r, str, 0, 0, color.NRGBA{0xff, 0xff, 0xff, 0xff})
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user