I am sending bytearray from unity to c++ plugin.
in unity
[DllImport ("dllplugin")]
public static extern void Method (byte[] bytes);
in c++ Plugin
#define EXPORT_API __declspec(dllexport)
extern "C" void EXPORT_API Method(unsigned char* bytes)
plugin receives the bytearray but not receives the complete byte array.for example unity sending the byte array size with 17 but C++ receives the byte array size with 4.
what is the problem with bytearray? how to receive complete byte array?