Skip to content
This repository has been archived by the owner on Oct 4, 2024. It is now read-only.
/ identicon Public archive

github's Identicons clone

License

Notifications You must be signed in to change notification settings

1l0/identicon

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

identicon

identicon is a github's Identicons clone in Go

Simple example

Type: Horizontal, Theme: White (Default)

package main

import "github.com/1l0/identicon"

func main() {
	id := identicon.New()
	id.GeneratePNGToFile("identicons/default")

Type: Vertical, Theme: Black

	id.Type = identicon.Mirrorv
	id.Theme = identicon.Black
	id.GeneratePNGToFile("identicons/vertical_black")

Divisions: 7, Theme: Gray

	id.Type = identicon.Mirrorh
	id.Theme = identicon.Gray
	id.Q = 50
	id.Div = 7
	id.GeneratePNGToFile("identicons/div7_gray")

Margin: 140, Theme: Free

	id.Theme = identicon.Free
	id.Q = 70
	id.Div = 5
	id.Margin = 140
	id.GeneratePNGToFile("identicons/margin140_free")

Type: Normal, Theme: White

	id.Type = identicon.Normal
	id.Theme = identicon.White
	id.Margin = 35
	id.GeneratePNGToFile("identicons/normal_white")

Random batch

	id = identicon.New()
	id.GenerateRandomThemes("identicons/rand", 4)

Sequential batch

	id.GenerateSequentialThemes("identicons/seq", 1)
}

About

github's Identicons clone

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages