home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.sys.mac.programmer
- Path: sparky!uunet!pageworks.com!world!eff!sol.ctr.columbia.edu!zaphod.mps.ohio-state.edu!magnus.acs.ohio-state.edu!usenet.ins.cwru.edu!agate!apple!mumbo.apple.com!gallant.apple.com!NewsWatcher!user
- From: nerm@apple.com (Dean Yu)
- Subject: Re: How to tell screen depth?
- Sender: news@gallant.apple.com
- Message-ID: <nerm-121192141721@90.10.20.86>
- Date: Thu, 12 Nov 1992 22:17:27 GMT
- References: <jvp.721588860@cpre1.ee.iastate.edu> <BxM74p.JzH@news.iastate.edu>
- Organization: Apple Computer, Inc.
- Followup-To: comp.sys.mac.programmer
- Lines: 29
-
- In article <BxM74p.JzH@news.iastate.edu>, niko@iastate.edu (Nikolaus E
- Schuessler) wrote:
- >
- > In article <jvp.721588860@cpre1.ee.iastate.edu> jvp@vlsi2.ee.iastate.edu (Jim Van Peursem) writes:
- > > How do I tell the screen depth of the monitor that one of my window's is
- > >in? I don't want to know if the computer has color quickdraw. I want to
- > >know whether to draw the window in color or not based on the pixel depth
- > >of the screen. Can anyone point me in the right direction please?
- > >
- >
- > You will wan't to use some combination of GetMaxDevice (or GetDevice on
- > something you know to be on the screen you're interested in). I forget exactly
- > what all the parameters are, but it returns a bitmap or window which
- > has a '.pixelDepth' field... if it is greater than 1 then color!
- >
- > Inside Mac V should have the details... Look under 'GetMaxDevice' ...
- > --
- > Niko Schuessler
- > Project Vincent Systems Manager email: niko@iastate.edu
- > Iowa State University Computation Center voice: (515) 294-1672
- > Ames IA 50010 snail: 272 Durham
-
- Under System 7, the best method is to use DeviceLoop. DeviceLoop will
- call your drawing procedure with the depth of the device you'll be drawing
- to. Check out Inside Mac VI, Graphics Devices, for details.
-
- -- Dean Yu
- Blue Meanie, Negative Ethnic Role Model, etc.
- Apple Computer, Inc.
-