Hey there. I could need some help with my Surface object.
I've been trying to implement clipboard input and output in my extension.
It does seem to work, but the image is distorted. The color channels are swapped, and the image is about 1 pixel off.
I guess that's because I'm missing something like a +1 for a memory address, however I'm more or less clueless.
Here's the save function. It's a little shorter than the load one, and I think it's enough for now.
Thanks for any input
Left: Source, Right: Clipboard
//Loads a surface from a vector in the rdPtr
cSurface* tmp = Image(img);
HGLOBAL cb = GlobalAlloc(GMEM_MOVEABLE,tmp->GetDIBSize());
BITMAPINFO* bmp = (BITMAPINFO*)GlobalLock(cb);