Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!gem.mps.ohio-state.edu!ginosko!uunet!microsoft!michaelt From: michaelt@microsoft.UUCP (Michael Thurlkill 1/1029) Newsgroups: comp.windows.ms Subject: Re: Bitmaps again...HELP Keywords: bitmap Message-ID: <7548@microsoft.UUCP> Date: 29 Aug 89 03:52:50 GMT References: <25217@genrad.UUCP> Reply-To: michaelt@microsoft.UUCP (Michael Thurlkill 1/1029) Organization: Microsoft Corp., Redmond WA Lines: 39 In article <25217@genrad.UUCP> cig@genrad.com (Charles I. Ganimian Jr.) writes: > > > 1st use snap to bring it into the clipboard then use paint > (or whatever) to modify it then put it back into the clipboard. > Next write an app which removes it from the clipboard and writes > it to a file. Is this possible?? Anybody have a clues. > This is definitely possible. In fact the "ClipBits" sample that comes with the SDK is structured to do just this. However, the 'Save' portion isn't emplemented, even though the menu selection is there. You could emplement this yourself pretty easily. Basically, you want to grab the bitmap off the clipboard, call GetBitmapBits to get the bitmap data, write out the following header, and then write out the bits. Reading the file would be sort of the reverse. Bitmap header: typedef struct { WORD dummy1; short bmType; short bmWidth; short bmHeight; short bmWidthBytes; BYTE bmPlanes; BYTE bmBitsPixel; DWORD dummy2; } BMFILEHDR; This is basically the same as the bitmap structure listed in the Data Structure section of the reference manual. Good luck, Mike Disclaimer: These thoughts and opinions are mine and noone elses. They shouldn't be misconstrued as being correct or related to my employer.