🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.amiga.tech
Article #1577

Re: Finding active screen

#1577
From: Daniel S. Riley
Date: Mon, 09 Oct 1989 14:13
26 lines
1647 bytes
In article <126033@sun.Eng.Sun.COM> cmcmanis@sun.UUCP (Chuck McManis) writes:
>In article <89281.222710CJC105@PSUVM.BITNET> CJC105@PSUVM.BITNET (Chris) writes:
>>How does one go about finding the active BitMap?  The method I am using now is:

>Not sure of the assem code, but try :
>	Lock = LockIBase();
>	bm = IntuitionBase->FirstScreen->Rastport.BitMap;
>	UnlockIBase(Lock);

I believe this gets you the frontmost screen, which isn't necessarily the
active screen (which I suppose is the screen with the currently active
window on it).  You might try instead

	Lock = LockIBase();
	bm = IntuitionBase->ActiveScreen->BitMap;
	UnlockIBase(Lock);

Screens.h claims that Screen.BitMap is an extra copy of the RastPort
BitMap.  You'll have to figure out the offsets yourself, or use the
handy structure definitions in the Commodore assembly headers.

Anyway, you wanting be looking in the public parts of IntuitionBase.
Gfx isn't responsible for this sort of stuff--Intuition is.

-Dan Riley (riley@tcgould.tn.cornell.edu, cornell!batcomputer!riley)
-Wilson Lab, Cornell U.
Technical Details
Message-ID: <9022@batcomputer.tn.cornell.edu>
Path: arc1-ca.pugleaf.net!utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!uflorida!uakari.primate.wisc.edu!gem.mps.ohio-state.edu!rpi!batcomputer!riley
References: <89281.222710CJC105@PSUVM.BITNET> <126033@sun.Eng.Sun.COM>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!uflorida!uakari.primate.wisc.edu!gem.mps.ohio-state.edu!rpi!batcomputer!riley
From: riley@batcomputer.tn.cornell.edu (Daniel S. Riley)
Newsgroups: comp.sys.amiga.tech
Subject: Re: Finding active screen
Message-ID: <9022@batcomputer.tn.cornell.edu>
Date: 9 Oct 89 14:13:29 GMT
References: <89281.222710CJC105@PSUVM.BITNET> <126033@sun.Eng.Sun.COM>
Reply-To: riley@tcgould.tn.cornell.edu (Daniel S. Riley)
Organization: Cornell Theory Center, Cornell University, Ithaca NY
Lines: 26