I started replacing 8bit numpy arrays with 32bit numpy. I resurrected Jon Nordby’s floating point libmypaint branch, too.
Even with OCIO active, performance seems to be actually much better than normal mypaint, which I suppose is partly because numpy32 is faster, but also there is less conversions going on, like all the fix15… Clearly, color for the tiles is horribly broken but at least it is compiling and running!
Here is the required OCIO libmypaint branch (really nothing to do with OCIO just keeping the name consistent):
https://github.com/briend/libmypaint/tree/OCIO
and the mypaint branch:
https://github.com/briend/mypaint/tree/OCIO
Memory usage for one layer is about 150MB for a 1080P screen. zoomed out to 50% (4X more area) and filling in the entire screen with a big air brush, the memory is 500MB. So, really not that bad at all IMO. I created 10 more layers and did some painting on each and my memory is at 1.5GB. I did basically the same thing in Krita (2000x4000 32bit) and created 10 more layers and it was about the same memory usage, so at least that much makes sense.
My assumption is that the color data is being skewed by some horrible incorrect data mismatch going from 8bit to 32bit, so hopefully the performance is not going to vanish as soon as I fix that.