fix spacing in example
This commit is contained in:
parent
18a0a84b99
commit
51e560e497
12
readme.md
12
readme.md
|
@ -9,17 +9,17 @@ usage:
|
||||||
```
|
```
|
||||||
import (
|
import (
|
||||||
"log"
|
"log"
|
||||||
"git.tuxpa.in/a/gotagonist/common/nori"
|
"git.tuxpa.in/a/gotagonist/common/nori"
|
||||||
)
|
)
|
||||||
func main() {
|
func main() {
|
||||||
n, err := nori.FromFile(filename)
|
n, err := nori.FromFile(filename)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Panicln("decode: %s", err)
|
log.Panicln("decode: %s", err)
|
||||||
}
|
}
|
||||||
// uses apng encoder/decoder from https://gitlab.com/gfxlabs/gfximg
|
// uses apng encoder/decoder from https://gitlab.com/gfxlabs/gfximg
|
||||||
animations, err := n.RenderAnimations(n)
|
animations, err := n.RenderAnimations(n)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Panicln("render: %s", err)
|
log.Panicln("render: %s", err)
|
||||||
}
|
}
|
||||||
// each animation has slice of frames
|
// each animation has slice of frames
|
||||||
// each frame contains an image.Image, if another format is needed
|
// each frame contains an image.Image, if another format is needed
|
||||||
|
|
Loading…
Reference in New Issue