chrisdill / raylib-cs

C# bindings for raylib, a simple and easy-to-use library to learn videogames programming
http://www.raylib.com/
zlib License
783 stars 68 forks source link

ExportImageToMemory uses wrong return type #244

Closed danilwhale closed 3 months ago

danilwhale commented 3 months ago

Before submitting a new issue, please verify and check:

Issue description

Original declaration looks like:

RLAPI unsigned char *ExportImageToMemory(Image image, const char *fileType, int *fileSize);

where unsigned char * should be byte* and not char*, because C char is equal to C# sbyte and unsigned char is equal to byte https://github.com/ChrisDill/Raylib-cs/blob/502a583e076cf1595a12def81206be7f804002e5/Raylib-cs/interop/Raylib.cs#L1371

chrisdill commented 3 months ago

Thanks, fixed!