You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
However, for something a bit more complex, like (source):
VP8StatusCode WebPGetFeatures(
constuint8_t* data, size_t data_size,
WebPBitstreamFeatures* features)
struct WebPBitstreamFeatures {
int width; // Width in pixels, as read from the bitstream.int height; // Height in pixels, as read from the bitstream.int has_alpha; // True if the bitstream contains an alpha channel.int has_animation; // True if the bitstream is an animation.int format; // 0 = undefined (/mixed), 1 = lossy, 2 = losslessuint32_t pad[5]; // padding for later use
};
java.lang.UnsatisfiedLinkError: unknown
at jnr.ffi.provider.jffi.AsmRuntime.newUnsatisifiedLinkError(AsmRuntime.java:48)
at de.digitalcollections.webp.lib.libwebp$jnr$ffi$0.WebPGetFeatures(Unknown Source)
The library is loading correctly, as simpler functions are working fine.
Maybe my translation is incorrect? Or maybe it's because the function is static ? Or because it's inline ? Or something to do with the pad that i didn't get correctly?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hi,
i am trying to use jnr-ffi to access
libwebp
. It works for some simpler functions, but i can't make it work for more complex ones.For example, the following function works (source):
Which I translated to:
However, for something a bit more complex, like (source):
which I translated to:
I call the function like so:
But i always get an error:
The library is loading correctly, as simpler functions are working fine.
Maybe my translation is incorrect? Or maybe it's because the function is
static
? Or because it'sinline
? Or something to do with thepad
that i didn't get correctly?Any help would be appreciated ! 🙏🏻
Beta Was this translation helpful? Give feedback.
All reactions