jimp-dev/jimp

Setting lower quality increases the file size

Ouverte

#1 018 ouverte le 2 juin 2021

 (0 commentaire) (0 réaction) (0 personne assignée)JavaScript (785 forks)batch import
bugfile size issuehelp wanted

Métriques du dépôt

Stars
 (13 218 étoiles)
Métriques de merge PR
 (Métriques PR en attente)

Description

Expected Behavior

Decrease the file size with decrement in image quality.

Current Behavior

Increase the file size with decrement in image quality.

Code

jimp.read("./forest-patrol.jpg", (err, lenna) => {
  if (err) throw err;
  lenna
    .quality(60) // set JPEG quality
    .write("./forest-patrol-jimp-mini.jpg"); // save
});

bug-report Here, we can see that original image forest-patrol.jpg is smaller than the processed image forest-patrol-jimp.jpg

Guide contributeur