A simple question about transparent acceleration of managed images:
I tried to access the pixels directly through Raster->DataBufferInt but as soon as I call:
DataBufferInt dbi = (DataBufferInt)(raster.getDataBuffer());
the image becomes non accelerated and there’s apparently no way to “re-accelerate” it.
I also noticed that setting the raster pixels with:
raster.setPixel(x,y,a,r,g,b);
works, but I suppose this solution gives very low performance expecially if compared to direct pixel access in the DataBuffer array.
so the question is: which is the best way to change the pixels of an accelerated (managed) image on the fly ?
Maybe an image copy ? Yes, could be, but imagine you want to direct-access the pixels to do some kind of filtering…
Mik