JNI C++ -> Java bitmap header info and bytes to jbytearray

时间:2015-06-15 14:34:08

标签: java c++ bitmap java-native-interface jbytearray

I'm using JNI to pass an image from C++ to Java, im trying to send the bytes in a jbyteArray over to Java in byte[]. However I'm getting an error which has most likely have to do something with the size of the bytes being send.

I have tried int len = dwBmpSize which have the same value but the jvm keeps crashing.

What is the correct amount of bytes to initialize the jbyteArray with?

0 个答案:

没有答案