Skip to content

Nacht1gall/animal-avatar-generator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Info

Python implementation of Animal Avatar Generator

All credit goes to the original creator

Installing

Install using `pip`:
pip install animal-avatar

Usage

from animal_avatar import Avatar
avatar = Avatar('your seed string')
svg = avatar.create_avatar()

Configuration options

Name Type Description Default
size int Avatar size in pixels 150
avatar_colors list Palette for avatar colors ['#d7b89c', '#b18272','#ec8a90','#a1Ac88','#99c9bd','#50c8c6']
background_colors list Palette for background colors ['#fcf7d1', '#ece2e1','#e4e3cd','#c4ddd6','#b5f4bc']
blackout bool Use blackout for right side of an avatar true
is_round bool Use round or rectangle shape true

Additionally you can install cairosvg and convert the result to an image:

from cairosvg import svg2png
svg2png(bytestring=svg, write_to='test.png')

About

SVG avatar generator (python)

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages