Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sun-barr!decwrl!pa.dec.com!wsl.dec.com!klee From: klee@wsl.dec.com (Ken Lee) Newsgroups: comp.windows.x Subject: Re: Getting the color of a pixel in a pixmap??? Message-ID: <1991Apr10.111343@wsl.dec.com> Date: 10 Apr 91 18:13:43 GMT References: <1991Apr10.162147.13975@ux1.cso.uiuc.edu> Sender: news@pa.dec.com (News) Reply-To: klee@wsl.dec.com Distribution: local,world,all Organization: DEC Western Software Laboratory Lines: 16 In article <1991Apr10.162147.13975@ux1.cso.uiuc.edu>, CWIKLA@uimrl7.mrl.uiuc.edu (John/Consultant) writes: |> |> Am I correct in thinking that the only way to get the color |> of a pixel in a pixmap is to put it into an XImage structure, and then |> use the XGetPixel function? XGetImage is the most reliable way to get the data to the client. You can use XGetPixel or other similar methods to get the individual pixel values. The actual colors associated with the pixel values depend on the current colormap. -- Ken Lee DEC Western Software Laboratory, Palo Alto, Calif. Internet: klee@wsl.dec.com uucp: uunet!decwrl!klee