v2 / vlib / gg / testdata / draw_arcs.vv
16 lines · 14 sloc · 337 bytes · 8745ab1ffffc18340ce4ea5c1a37c8fcea130937
Raw
1module main
2
3import math
4import gg
5
6gg.start(
7 window_title: 'Arcs'
8 width: 200
9 height: 200
10 frame_fn: fn (mut ctx gg.Context) {
11 ctx.begin()
12 ctx.draw_arc_filled(100, 100, 35, 45, 0, f32(math.radians(290)), 30, gg.red)
13 ctx.draw_arc_empty(100, 100, 30, 50, 0, f32(math.radians(290)), 30, gg.white)
14 ctx.end()
15 }
16)
17