Skip to content

Commit

Permalink
use Jimp.resize for thumbs
Browse files Browse the repository at this point in the history
  • Loading branch information
edsilv committed Oct 2, 2018
1 parent a3731df commit 7d65fb2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion Utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,8 @@ export class Utils {
// const pathToBuffer: string = imagePath.substr(0, imagePath.lastIndexOf('/')) + '/buffer.txt';
// fs.writeFile(pathToBuffer, arrBuffer);
// });
thumb.cover(config.thumbnails.width, config.thumbnails.height);
//thumb.cover(config.thumbnails.width, config.thumbnails.height);
thumb.resize(config.thumbnails.width, Jimp.AUTO);
pathToThumb += image.getExtension();

thumb.write(pathToThumb, () => {
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "biiif",
"version": "0.3.12",
"version": "0.3.13",
"description": "A CLI to build IIIF collections",
"main": "index.js",
"repository": {
Expand Down

0 comments on commit 7d65fb2

Please sign in to comment.