Show HN: A pure WebGL image editor with filters, crop and perspective correction
github.comI'm working on a pure js webgl image editor with effects, filters, crop & perspective correction, etc. My goal is to give the community an opensource solution as unfortunately most comparable apps are closed sources.
https://mini2-photo-editor.netlify.app to try it out (https://github.com/xdadda/mini-photo-editor)
I've been looking for an open source image editor that I can embed in my app for managing my vintage ad archives (https://adretro.com). Basically I just need to rotate, crop, adjust color. But the images come from from the archive database rather than upload. And I want to work with them quickly, rather than save/open like a desktop app. Last time I looked I couldn't find something with good documentation that was easy to get started with. Right now I bulk edit in Google Photos.
Excellent work. The UI looks very clean and functional. It's feature packed. Good choice on using WebGL. It has support everywhere in most if not all browsers.
I'm so glad this exsist. I've been meaning to get something similar started, but did not due to one reason or the other. I'll definitely try to contribute.
Whenever you feel like, ping me on github
Nice. I tried it with an image from Unsplash. Maybe you can use the Unsplash API[1] to give people an example to play with.
[1]: https://unsplash.com/developers
Will have a look at this thanks! in the meantime I've added a quick sample gallery to test the editor out
Did you consider using WebGPU, or creating a bridge between WebGPU / WebGL for this? Also, have you considered deploying on Cloudflare Pages [1] (unlimited bandwidth) instead of netlify?
[1] - https://pages.cloudflare.com/
I did consider WebGPU but I couldn't find many advantages for the current use case.
Yes I'm planning to move to the edge as soon as it's in a later stage of development
Apparently it isn't unlimited: https://news.ycombinator.com/item?id=42713451
in the editor, do add a way to load sample random image to try out the editor instead of having to uploading my own (which most won't bother / don't trust / can't do at work).
Great advise. Will add it next.
Bust just to be clear, images are handled 100% locally on the user machine. No data is sent to servers, no adv, no cookies, nothing ...
Yup I get that.
sample images added. thanks for the tip
Lol, I added a todo yesterday: "find or build good image cropper, ideally gl based" ;)
Guess the search might be over, thanks!
let me know of any usability issue. I tried different combinations and this seemed intuitive for me (compared to other solution), but of course I'm too biased.
This is neat. Any plans to add blurs and related effects?
yes, I don't use them but if required it will be easy to add
Very cool! What's the license, and how does it compare to some of the other croppers/editors out there? Was it mainly the GL integration?
Ops forgot to add MIT license As for the underlying modules on which it relies Will fix it shortly
What does comparable refer to here? Web based image editors? Like what?
there are several web based image editors leveraging webgl out there.
Some of them are very good such as https://img.ly/products/photo-sdk or https://www.polarr.com/web/ or https://pqina.nl/pintura/
I hope to match some of them in terms of features, but with a lightweight and opensource solution
Nice! Good performance, clean UI, and core functionality.
thanks. It started as a proof of concept for a custom reactivity engine (based on signals and tagged template literals). But while at it I realised I needed something quick and easy for my needs.
I already have a prototype for a self-hosted photogallery that integrates this editor (something like https://immich.app to give you an idea). But it's still too early to share
Thank you for sharing!
What's the license?
MIT. thanks for point that out, I did forget to add it
I tried to figure out how to crop an image and found nothing. There doesn't seem to be a crop feature as far as I could tell. I'm sure it's probably there, but not easy for anyone to figure out. Would be super easy to make it intuitive right?
it's the composition menu ... will rename it
just select the area you wish to crop and then move to the other settings (colors, ...) to edit it
I did this but when I hit download, I got back the original image instead of the cropped image.
I tried it again, and finally noticed you have to click the corner of the image to move the selection area. It works, but then I didn't see a "Crop" button. Only trying to be helpful, and not complaining. Nice work tho on this component.
No no I absolutely need this kind of feedback thanks! Being a solo developer is very difficult to gage usability and UX is definitely not my strength.
I tried to integrate the crop/ composition in the natural workflow of image processing, without a discreet "crop" button. But I guess it's not necessarily the most intuite thing to do :)
good AF
thanks!