Convert image to ASCII
go get https://github.com/qeesung/image2ascii
package main
import (
"fmt"
"github.com/qeesung/image2ascii/convert"
_ "image/jpeg"
_ "image/png"
)
func main() {
fmt.Print(convert.ImageFile2ASCIIString("example/images/baozou.jpg", &convert.Options{
Ratio: 0.5,
}))
}
Raw Image | ASCII Image |
---|---|