nodejs-watermark
v0.1.7
Published
Simple solution for watermarking images with other images.
Downloads
4
Readme
nodejs-watermark
See the demo (master branch of this repo deployed to Heroku)
- Install GraphicsMagick on your machine (or a buildpack on your server)
- Clone this repo:
[email protected]:retzion/nodejs-watermark.git
- Install dependencies:
npm i
- Run it:
npm run start:dev
- Try it out:
http://localhost:3000/https%3A%2F%2Fpicsum.photos%2F1200%2F777
- Try adding some params:
http://localhost:3000/u/https%3A%2F%2Fpicsum.photos%2F1200%2F777?resize=1200,660&geometry=660,540
Params:
Include geometry
and resize
as querystring parameters in order to customize the image.
resize
: Tuple of X, Y dimensions for resizing the base image (?resize=800,450
)geometry
: Tuple of X, Y coordinates for where to place the watermark (?geometry=30,30
)
resources:
Heroku Buildpack: https://elements.heroku.com/buildpacks/xerpa/heroku-buildpack-graphicsmagick