grpc_client

command
v0.0.0-...-db727bb Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 27, 2022 License: MIT Imports: 11 Imported by: 0

README

grpc-client

grpc-client, works with running server

can be used to draw text over source image, result is saved in working directory

flags:

-a          specify server address and port (default: "localhost:50051")
-s          source image url or base64 encoded image, only jpeg and png are supported (required)
-t          text to draw over source, "@" will be replaced with "\n", up to 3 lines of text supported
-o          output file name, saves file in working dir, output is always png (default: "out.png")
-h,--help   prints help message
--fonts     prints fonts file names available on server

drawing options (optional):

-i,         use font with index i, font list can be obtained with --fonts flag
--fscale    relative font scale, higher values will give bigger glyphs (values: 1-4)
--fcolor    rgb hex color as string, i.e. "ffffff", also supports "random" value, which will give random color
--ocolor    same as above, but for outline
--oscale    same as font scale, but for outline
--nooutline disable outline drawing
--distort   add noise to glyph coordinates

running command:

go run . -s "https://avatars.githubusercontent.com/u/89552583?v=4" -t "test@TEST@test" --fcolor 0000f0 --ocolor random --oscale 4 --fscale 3 -i 6 --distort

will produce image:

Example

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL