Avatar Generator
Generates default avatars from a given string (such as username). This is mainly for an usage in web apps, but you can also use it to populate LDAP "jpegPhoto" field, for instance.
Installation
pip install avatar-generator
Example in a Flask app
from avatar_generator import Avatar
from flask import make_response
@app.route("/photo.png")
def photo():
avatar = Avatar.generate(128, "example@sysnove.fr", "PNG")
headers = { 'Content-Type': 'image/png' }
return make_response(avatar, 200, headers)
Licence
This code is under WTFPL. Just do what the fuck you want with it.
Metadata
Release files for avatar-generator 0.4.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| avatar-generator-0.4.2.tar.gz | 37.5 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| avatar_generator-0.4.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 74.2 kB
Release files / avatar-generator-0.4.2.tar.gz
| Download URL | avatar-generator-0.4.2.tar.gz |
|---|---|
| Size | 37.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
14d9ec78cd0a2e10d376044818b3e9a1ec6e371ca42f307cff73e6b5fb15320c
|
|
BLAKE2b-256 checksum How to use checksums |
e28975c264aa978864e6a00bffdcbe3cb2ffdf9bf47f6d4291196b2a927b84d8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.11.7
|
Release files / avatar_generator-0.4.2-py3-none-any.whl
| Download URL | avatar_generator-0.4.2-py3-none-any.whl |
|---|---|
| Size | 36.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
1943a89337819742a71048dca2132754241477b80adda9a6509774ed0639b6ad
|
|
BLAKE2b-256 checksum How to use checksums |
7a6418d0a494336620bfcaf88ea0d692db2a35edf23b27790dbfc52930570bc4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.11.7
|