-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
OSX - GdkPixbuf-WARNING when converting an SVG to PNG #588
Comments
Hello, are you using a global version of libvips installed via homebrew? |
Hi, I did actually switch to using the Homebrew version of libvips found here - http://www.vips.ecs.soton.ac.uk/index.php?title=Build_on_OS_X - and it worked. Thank you for looking into the issue. |
Use of a homebrew-installed copy of vips is not required to use sharp on OS X. However I know some people do use it and the mention of a global path The SVG to PNG use case is included in the tests and seems to work on OS X using the pre-built binaries. A recent commit to Homebrew/homebrew-core#4259 suggests the "Cannot open pixbuf loader module file" error is or at least has been a known problem with a homebrew-installed gdk-pixbuf. My best guess here is that an older version of gdk-pixbuf has previously been installed globally (perhaps as a dependency of something else) and was somehow being used in preference to sharp's own bundled version of it. |
I'm running Sharp 0.16.0 on OSX 10.11.6, and am currently trying to convert a buffered SVG to a PNG file with the following code:
sharp(cmon).toFile('new.png');
The SVG contains an embedded image (data URL).
This works fine on Windows. The PNG is produced as expected.
However, on OSX, the PNG file prints, but does not display the embedded image.
The terminal window also prints the following:
Has anyone else encountered this issue? Are there any simple fixes or work arounds?
The text was updated successfully, but these errors were encountered: