Dummy Image Generator allows you to dynamically create and return images of various sizes, colors and styles, providing flexible customization of image generation through a simple and user-friendly URL interface.
Built with Go 1.21.4
- Executable file
- Config
config.yaml
- Fonts
arial.ttf
- Resources
favicon.ico
- Static
css
img
js
- Views
index.html
- server
- addr
host
:port
- addr
- image
- default_format
image format
- size
- min_size
size format
- max_size
size format
- size_clamp
bool
- min_size
- color
- default_background_color
color format
- default_text_color
color format
- default_background_color
- default_format
go mod download
go build -ldflags="-s -w" -o http_server.exe cmd\http_server\main.go
.\http_server.exe
Example for Windows
/ size
/ background_color
/ text_color
/ format
? text
-
Size:
100x100
100
HD
and other...Required
-
Color:
F
FF
FFF
FFFFFF
255,255,255
White
and other...Default: background is
Black
text isWhite
-
Text:
Hello world
no_text
Default:
width x height
-
Image:
PNG
JPEG
WEBP
GIF
SVG
Default:
PNG
- Min size:
10x10
- Max size:
2000x2000
Automatic size clamp
Examples
http://127.0.0.1:8080/800x800/FFF/000/gif?text=Hello%20world
size, background_color, text_color, format, text
http://127.0.0.1:8080/HD/F1E2D3/webp?text=Hello%20world
size, background_color, format, text
http://127.0.0.1:8080/400
size
Name | Module | Version |
---|---|---|
gin | github.com/gin-gonic/gin | 1.9.1 |
viper | github.com/spf13/viper | 1.17.0 |
logrus | github.com/sirupsen/logrus | 1.9.3 |
gg | github.com/fogleman/gg | 1.3.0 |
webp | github.com/chai2010/webp | 1.1.1 |
svgo | github.com/ajstarks/svgo | 0.0.0 |