UNPKG
multi-djs
Version:
latest (0.0.16)
0.0.16
0.0.15
0.0.14
0.0.12
0.0.10
0.0.9
0.0.8
0.0.7
0.0.6
0.0.4
0.0.2
A npm of image manipulation, gif catcher and functions
multi-djs
/
src
/
photoshop
/
circle.js
8 lines
•
268 B
JavaScript
View Raw
1
2
3
4
5
6
7
8
module
.
exports
=
async
(image) => {
if
(!image)
throw
new
Error
(
"Parâmetro <image> não definido!"
);
const
jimp =
require
(
"jimp"
); image =
await
jimp.
read
(image); image.
circle
();
let
raw =
await
image.
getBufferAsync
(
"image/png"
);
return
raw; }