Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: Ignore unsupported quality parameter for PPM files #309

Merged
merged 1 commit into from
Jul 20, 2024

Conversation

dichiban
Copy link

@dichiban dichiban commented Jul 20, 2024

Using PPM files were giving errors as vips does not support -Q (quality) parameter.

vips VipsForeignSavePpmFile 
save image to ppm file
usage:
   ppmsave in filename [--option-name option-value ...]
where:
   in           - Image to save, input VipsImage
   filename     - Filename to save to, input gchararray
optional arguments:
   format       - Format to save in, input VipsForeignPpmFormat
			default enum: ppm
			allowed enums: pbm, pgm, ppm, pfm, pnm
   ascii        - Save as ascii, input gboolean
			default: false
   bitdepth     - Set to 1 to write as a 1 bit image, input gint
			default: 0
			min: 0, max: 1
   keep         - Which metadata to retain, input VipsForeignKeep
			default flags: exif:xmp:iptc:icc:other:all
			allowed flags: none, exif, xmp, iptc, icc, other, all
   background   - Background value, input VipsArrayDouble
   page-height  - Set page height for multipage save, input gint
			default: 0
			min: 0, max: 10000000
   profile      - Filename of ICC profile to embed, input gchararray
operation flags: sequential nocache 

So just ignore it like we do with png files.

related issue

@rbuchberger rbuchberger merged commit 3e9bfcb into rbuchberger:master Jul 20, 2024
1 check passed
@rbuchberger
Copy link
Owner

Thanks so much! I should probably switch it around and only provide a quality on formats where we know it will work, but that can be later.

I’ll get a release out asap

@dichiban dichiban mentioned this pull request Jul 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants