examples/vector: Render more texts

This commit is contained in:
Hajime Hoshi 2019-04-14 01:58:20 +09:00
parent d7bd89d32b
commit 8d912a402f

View File

@ -35,8 +35,54 @@ func update(screen *ebiten.Image) error {
} }
var path vector.Path var path vector.Path
// E
path.MoveTo(20, 20) path.MoveTo(20, 20)
path.LineTo(30, 50) path.LineTo(20, 60)
path.MoveTo(20, 20)
path.LineTo(60, 20)
path.MoveTo(20, 40)
path.LineTo(60, 40)
path.MoveTo(20, 60)
path.LineTo(60, 60)
// B
path.MoveTo(80, 20)
path.LineTo(80, 60)
path.LineTo(110, 60)
path.LineTo(120, 50)
path.LineTo(110, 40)
path.LineTo(120, 30)
path.LineTo(110, 20)
path.LineTo(80, 20)
path.MoveTo(80, 40)
path.LineTo(110, 40)
// I
path.MoveTo(140, 20)
path.LineTo(140, 60)
// T
path.MoveTo(160, 20)
path.LineTo(200, 20)
path.MoveTo(180, 20)
path.LineTo(180, 60)
// E
path.MoveTo(220, 20)
path.LineTo(220, 60)
path.MoveTo(220, 20)
path.LineTo(260, 20)
path.MoveTo(220, 40)
path.LineTo(260, 40)
path.MoveTo(220, 60)
path.LineTo(260, 60)
// N
path.MoveTo(280, 60)
path.LineTo(280, 20)
path.LineTo(320, 60)
path.LineTo(320, 20)
op := &vector.DrawPathOptions{} op := &vector.DrawPathOptions{}
op.LineWidth = 4 op.LineWidth = 4