feat: compress media files #818
Loading…
x
Reference in New Issue
Block a user
No description provided.
Delete Branch "dpschen/frontend:feature/compress-media-files"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
I created a new folder called "originalMedia" where I move all the uncompressed images.
I moved most assets to the src folder. This makes the build a little bit slower but has the advantage that vite will can add a content hash.
I converted llama-nightscape to jpg because I got better compression results with that. Not sure if that makes sense though (because of todays high dpi displays).
Used for SVG: manual lossy (!) compression with SVGOMG
I would have loved to manually check the layers and see if I could combine / remove some manually.
That's an optimisation step that SVGOMG obviously can't do. Sadly Inkscape seems to have some stability problems when opening these SVGs... weird.
I did not compress the "safari-pinned-tab.svg" because SVGOMG seemed to have some problems with it.
Used tool for oll other images: ImageOptim v1.8.8 (sadly just for macOS, but it simply combines many image compression api under one GUI, combines them sometimes, lets them compete and uses the best outcome).
I stripped all meta data with a lossy (!) compression of 85% for JPEG, 80% for PNG (yes PNG supports lossy compression) and optimisation level "insane".
I enabled all supported compression algorythms except Guetzli (time is just too crazy)
I compressed the wav file with
ffmpeg -i pop.wav pop.mp3
.Note: I realised that the full-pride logo has a different outer offset that the other logo (from the circle around the llama).
This seemed to be not by intend.
dde1f982da
to88b6dd88f7
88b6dd88f7
to955bd73fec
Might make sense to exclude the originalMedia folder from builds.
@konrad Didn't expect you to merge it right away :D
I guess everything is fine, just wanted some feedback regarding the points in the pull request description on top :)
Ah, I though it was fine as well :) Didn't understand that you were looking for feedback, sorry for that.
I think that's still fine. The image is mostly used on mobile devices (because that's where you loose internet more often than on other devices) and it should still look great in that resolution.
That's interesting, I can open them just fine.
That was actually generated when I created the pwa icons. I don't remember what tool I used back then though. Might be that led to some problems, the icon looked fine on my Safari tests though.
That is correct, that was not intended. It looks okay though so...