I have an ActiveX control that provides such method: void GetCurrentImage(long theFormat, VARIANT * theBuffer, long * theBufferSize);
I want to get a byte image buffer from this function. That is, I am trying to do this: long image_size;
VARIANT FrameBuf[1024*1024];
char ByteBuf[1024*1024];
// Get a pointer pCtrl to the ActiveX Control
pCtrl->GetCurrentImage(0, FrameBuf, &image_size);
// How to convert FrameBuf to ByteBuf?
I did some googling. But partly because VARIANT is a common word that confused Google, I can hardly find any useful solution to this. Can anyone give me some advice? Thank you very much.