Create beautiful generative image patterns from a string in golang.
Go port of Jason Long's awesome GeoPattern library.
Read geopattern's development story geo_pattern: going on the Go path
Generate beautiful tiling SVG patterns from a string. The string is converted into a SHA and a color and pattern are determined based on the values in the hash. The color is determined by shifting the hue from a default (or passed in) base color. One of 16 patterns is used (or you can specify one) and the sizing of the pattern elements is also determined by the hash values.
You can use the generated pattern as the background-image for a container. Using the base64 representation of the pattern still results in SVG rendering, so it looks great on retina displays.
See the GitHub Guides site as an example of this library in action. GitHub Guides use Original Ruby implementation.
go get github.com/pravj/geopattern
Example directory contains sample go programs that explains use of geopattern
args := map[string]string{"phrase": "My Custom Phrase"}
args := map[string]string{"generator": "plaid"}
args := map[string]string{"color": "#3b5998"}
args := map[string]string{"baseColor": "#ffcc00"}
Generate(args)
Base64String(args)
URIimage(args)
go-colorful : for color space conversion
Made with Muzi and Appy by Pravendra Singh