dariju
Erlang or Elixir wrappers for libvips
I need a wrapper for LibVips. I have found 2 ones
Those are unpopular - 11 and 14 downloads.
Are there other ones, in Erlang or Elixir, that are used by most people and are recommended?
Trending in Questions
I’m in search of an Elixir library that offers PDF generation capabilities similar to Ruby’s Prawn. While there have been discussions abo...
New
I’m looking to build a personal workflow to quickly deploy web applications written in elixir/phoenix, for local consumption (ie not on t...
New
Using Phoenix.LiveView.TagEngine as an EEx.Engine is deprecated!
To compile HEEx, use Phoenix.LiveView.TagEngine.compile/2 instead.
Sta...
New
Hello !
We want new/edit form pages to POST/PUT to their own URL rather than the resources REST defaults (post /things, put /things/:id)...
New
Before I dive in myself, did anyone successfully sprinkle Hologram into their existing LiveView app?
Looking for hints regarding:
Addi...
New
Hi all, I wanted to ask how the community is dealing with post-release steps.
Today we have Ecto migrations, which make sure that the db...
New
I am using Oban and occasionally, shortly after a deployment, a handful of jobs can fail because of dependency on other parts of the syst...
New
Other Trending Topics
Hey, I’m Jesse and I’m the main contributor behind Dexter, a full-featured, lightning-fast Elixir LSP optimized for large codebases. It s...
New
Beam Bots (or just BB for short) is a framework for building fault-tolerant robotics applications in Elixir using familiar OTP patterns. ...
New
Hello everyone. After busy few months I am happy to announce v0.1.0 of Emerge & Solve.
They are GUI (Emerge) and State management (S...
New
Emily is an Elixir library that runs Nx computations on Apple’s MLX. Install it as the default Nx backend and Nx, defn, Axon, Nx.Serving,...
New
I just stumbled on a newly redesigned elixir-lang.org. :tada: It looks like @Software_Mansion did the work, and I think it is generally a...
New
@hugobarauna and I (Alex Koutmos) have been hard at work on writing a book on Nerves that takes you from simply blinking LEDs to building...
New
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #deployment
- #library
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #channels
- #elixirconf
- #exunit
- #discussion
- #code-sync
- #javascript
- #podcasts
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #elixir-ls
- #phoenix_html
- #iex
- #blog-post
- #graphql
- #genstage
- #ai
- #websockets
- #elixirconf-us
- #supervisor
- #advent-of-code
- #distillery
- #processes
- #api
- #forms
- #metaprogramming
- #performance
- #security










First 10 of 14 Posts!
kip
Of the two you found, none are a
lipvipswrapper. vips | Hex wraps the command line version. The other is notlibvipsrelated. Like you, I’d like to see a NIF-basedlibvipswrapper but my NIF-fu is weak.foggy
Just recently met someone who was messing around with this in their spare time GitHub - christianjgreen/elixir-libvips: Experimental bindings for libvips · GitHub.
It may at minimum be informative as to how to do what you need if what you need isn’t too broad.
christianjgreen
Hey @foggy! Hope you’re doing well dude.
That library is something that I was working on for fun, but as it started to reach a decently stable-ish point. The blocker for me moving forward was ensuring safety for the user as scaling LibVips in a massively concurrent manner can lead to crashes that trickle up to the BEAM.
I’d love to help if you have any questions!
christianjgreen
So I started to dig into the native code to see what I was doing wrong, because when it comes to concurrency, it’s usually my fault. In this case the issue was garbage collections was done globally and not on a per BEAM thread basis. I think I might pick this project back up if there’s any interest in it.
kip
Yes, please do! If you get the bones of it right for dirty scheduling and concurrency I’ll happily contribute!
kip
I particularly hopeful that from an API perspective I can pass a pipeline of operations and desirably work on an in-memory version of the image (and of course read and write).
christianjgreen
By a “pipeline” do you mean something like the lines of:
Libvips operations in this instance would pass a “ref” back and forth to avoid unnecessarily crossing the NIF bridge with the image data.
kip
Spot on, and sorry for not being clearer. Be able to send multiple transformations to the NIF for execution without passing back and forth - or as you say, keep a ref so that the image isn’t being copied all the time.
This is a topic long on my list since photography is a passion and rebuilding my portfolio site is something I want to do from the ground up. Including the image processing layer (because I want to). I just haven’t done any C programming since Kernighan and Ritchie first came out. So I’m a little out of date …
jesselatham
Hi guys,
A little late to the game here but I’d also love to see some work done around vips in support of Elixir after having used it with Rails projects at the last company I was with.
I had enjoyed its performance and ease of use over imagemagick and rmagick along when using the GitHub - libvips/ruby-vips: Ruby extension for the libvips image processing library. · GitHub project. It would be great to offer this to the community and I’m willing to help out in any way I can (testing, documentation, picking up C along the way and so on).
And pipelining would be awesome to have as Kip has confirmed would be awesome (at least to get to with future versions).
@christianjgreen / @kip
Cheers guys!
christianjgreen
Hello everyone! I’ve been quite busy with trying to drink that stupid water stuff, but I’ve been able to put a little bit of thought into this and hope to explain why the final NIF project was never released.
As we all know NIFs have their niche case, but something as high-level as libvips should probably be handled through a port. I severely underestimated the bandwidth of ports and made the insecure trade-off to NIFs in order to focus on performance. I had a nice chat with some folks from AtomVM (specifically @cdegroot) and got some insight on the true performance ports can provide. The port solution, in my opinion, decouples the image manipulation interface and provide a “safer” environment for the BEAM.
I would love some feedback from the community about this! I know some folks already “sandbox” their NIF nodes and/or don’t care about the potential crashes due to their infrastructure, so the final question is - Which interface will rule them all? Maybe a libvips API that can be accessed through both NIFs and ports?
<3
Last Post!
cvkmohan
@akash-akya Wonderful work. You know the best part of the library? The two LiveBooks. I think we are in for some revolution in terms of documentation for elixir libraries.
Thanks for the good work.