run gen_readme
This commit is contained in:
parent
fb232a8d4a
commit
47544f64c4
1 changed files with 4 additions and 9 deletions
13
README.md
13
README.md
|
@ -282,16 +282,11 @@ image.fillPath(path, paint)
|
|||
### Shadow
|
||||
[examples/shadow.nim](examples/shadow.nim)
|
||||
```nim
|
||||
let path = newPath()
|
||||
path.polygon(vec2(100, 100), 70, sides = 8)
|
||||
|
||||
let polygonImage = newImage(200, 200)
|
||||
|
||||
let ctx = newContext(polygonImage)
|
||||
ctx.fillStyle = rgba(255, 255, 255, 255)
|
||||
|
||||
ctx.fillPolygon(
|
||||
vec2(100, 100),
|
||||
70,
|
||||
sides = 8
|
||||
)
|
||||
polygonImage.fillPath(path, rgba(255, 255, 255, 255))
|
||||
|
||||
let shadow = polygonImage.shadow(
|
||||
offset = vec2(2, 2),
|
||||
|
|
Loading…
Reference in a new issue