Hi all
I am trying to implement something similar to the signature++-1 sample which
converts a signature to a bitmap and uses a conduit to store it on the desktop.
The sample creates an offscreen window to copy the bits bounded by the gadget and then
copies the gadget's screen rectangle into the new window. It then allocates the bitmap
and sets all the important bits of information.
The sample is using some functions which are not probably supported. like:
theBitmapPtr->height = theWindowHandle->gDeviceP->height;
theBitmapPtr->rowBytes = theWindowHandle->gDeviceP->rowBytes;
etc.
theWindowHandle is of type WinHandle. The document describes WinHandle as: typedef
WindowType * WinHandle;
and WindowType structure nowhere has member like gDeviceP.
The compiler barfs at gDeviceP saying unidentified identifier( obviously)
I have replaced the gDeviceP with bitmapP , but have run into memory problems where
the program tries to move the offscreen bits into the bitmap.
// Move the offscreen bits into our bitmap. The baseAddr field
// contains the bit array of our bitmap for 1-bit, uncompressed //bitmaps.
MemMove( (MemPtr)((UInt32)(theBitmapPtr) + sizeof(BitmapType)),
theWindowHandle->gDeviceP->baseAddr, theRowBytes * theHeight );
// I have replaced theWindowHandle->gDeviceP->baseAddr with theWindowHandle->bitmapP
but the error says that Application has just read directly from memory location which
is in an unallocated chunk of memory.
How do I get the base address of the bitmap?
PS : I am using ver PalmOS 3.2
I hope it is clear.It would be very kind of anyone who's been there to help me out.
thanks a Ton
Vijay
____________________________________________________
Buy Feng Shui Package for Rs. 151/- only, at
http://shopping.rediff.com/shopping/fengshui_mailer.htm
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/tech/support/forums/