Leszek S wrote:
It’s hard to say what could be the problem so I can only advice you to debug it more. You did not show what is SDFInMap. Maybe SDFInMap is a wrong pointer and not the pointer returned by getData(). Did you check that? Did you check to what data point both pointers? Is getData() pointer NULL or random value?
SDFInMap is just simple array.
unsigned char SDFInMap[WIDTH * HEIGHT * 4];
unsigned char SDFOutMap[WIDTH * HEIGHT * 4];
SDFInmap is not wrong pointer.
I had replaced image~~>getData to SDFOutMap.
In this case memcpy did not crash.
therefore I conclude image~~>getData() is returning wrong pointer.
Any way this is working well on iOS platform.
I suspect CCImage::getData() has a bug on Android platform.