I’m not ignoring any of that stuff, and I’m using Image::BitmapData. You didn’t answer the question. Given the function:
Image createConvolvedImage (Image sourceImage)if the following code executes on the Mac:
Image sourceImage (Image::RGB, ....);
...
image resultImage = createConvolvedImage (sourceImage)Then createConvolvedImage will see an image of type ARGB and produce the wrong result.
Here’s the other problem. Given the following code:
Image mask = Image (Image::SingleChannel, ...);
Image result = createConvolvedImage (mask);In the implementation of createConvolvedImage(), which ImageType should it use? It can’t use the core graphics / native image type on Mac OS / iOS because it doesn’t support single channel. But if we always use the software image type then the result is less optimal when getting called with ARGB / RGB images. Should there be a special case for single channel images, just because of a platform peculiarity? I don’t think so.
