egw.weakm@p3.lanl.gov (Eric Wasserman) (01/18/91)
References: <4901@media-lab.MEDIA.MIT.EDU> Organization: LANL In article <4901@media-lab.MEDIA.MIT.EDU> gslee@media-lab.MEDIA.MIT.EDU (Gene Lee) writes: > How can I get the pixelmap of the screen? I know how to get > the pixelmap of a particular window, but not the desktop screen? > Where is the screen's pixelmap located? I think what you need is the gdPMap field of the GDHandle returned by such calls as GetMainDevice() etc. (See IM V chapt. 5). Major caveat: I've successfully used the baseAddr field of this pixel map for direct writes to video RAM on an Apple 13" with an Apple card (I know, I know, I should do that but sometimes QuickDraw isn't quick enough.). Unfortunately, the same trick apparently doesn't always work with other video cards and monitors. For example, with a Radius DirectColor board and a 19" Radius Color monitor the baseAddr field comes back as a null pointer though the other fields of the pixel map seem to be filled in properly. Does anyone understand why baseAddr wouldn't be filled in properly? Specifically, how the heck does QuickDraw know where the video RAM is? Is there a better way to get at it? [BTY I'm not doing this in a commercial program so when it breaks only I will suffer.] Eric egw.weakm@p3.lanl.gov