Losing the quality of png images after uploading to prismic
I have 2 questions
Can you help me with the query to be appended in img URL with which i can extract best quality image ? by default I get auto=compress,format in URL, do i need to remove this and then add q=100 ( no success even after trying different suggested combinations of query for img url )
Does this q=100 work for png format ? if not, what is the format in which i should upload image to get the best quality images ?
Note: I am not comparing image formats I’m just comparing original png image uploaded with the prismic returned image. I can see a little blur in compressed images returned via prismic i need original quality image. ( mentioned png specifically because it is lossless and as far as i know q=100 would work on lossy formats ( jpeg, webp etc ) only
Are doing any compression on your side to the image at all before you upload it to our servers?
Because I took the original image that you added above and added it to one of my repos and it's being returned untouched at the right size. Also there is no white border on the sides like in the examples that you showed me above.
Please try uploading this original image again to see if that helps.
The issue here is that the Prismic API automatically adds the ?auto=compress,format to the image URL. We do not want that. We want to get the original image, without any modification. The only way that works is the one mentioned above, stripping the suffix from the URL provided by Prismic. It would be nice to have a built-in way to get the clean URL, without any compression nor enhancement.
Hello @soeren, welcome to the community.
I understand your suggestion. We implemented Imgix auto compress settings automatically to improve the API experience and the performance of your project. Here are all the details about this decision:
@Pau I have an issue also losing the quality of the uploaded images but in my case I lose the quality when doing the upload to prismic media library. I have an png image that is 1920x960 that when I open it locally it looks fine but when I see a preview after uploading it to the media library it looks all blurry, same as when I use it in my site, even with the enhance argument. Is prismic compressing the images at when uploading ?