🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.ibm.pc
Article #7666

Re: Getting at screen memory with MSC

#7666
From: Fred Smith
Date: Mon, 27 Nov 1989 21:47
25 lines
1124 bytes
In article <2922@sparky.UUCP> person@sparky.UUCP (Brett G. Person) writes:
>
>I need to access screen memory directly under microsoft C( actually QuickC).
>I know that the answer is to use a pointer to screen memory, but I don't
>know how to do this in C. This is probably painfully simple, but I don't
>know how to do it. 
>What I need to do is read screen memory starting at $b000:$8000 ( cga text
>mode).  respond via e-mail
>



Try:

	char far * screen_memory;

	FP_SEG(screen_memory) = 0xb000;
	FP_OFF(screen_memory) = 0x0000;

Note that this MUST be a FAR pointer regardless of memory model, since it 
does NOT lie in any segment which is allocated to your program.

Hope this is adequate help.

Fred
Technical Details
Message-ID: <8090@cg-atla.UUCP>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!samsung!cg-atla!fredex
References: <2922@sparky.UUCP>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!samsung!cg-atla!fredex
From: fredex@cg-atla.UUCP (Fred Smith)
Newsgroups: comp.sys.ibm.pc
Subject: Re: Getting at screen memory with MSC
Message-ID: <8090@cg-atla.UUCP>
Date: 27 Nov 89 21:47:36 GMT
References: <2922@sparky.UUCP>
Reply-To: fredex@cg-atla.UUCP (Fred Smith)
Organization: Agfa Compugraphic Division
Lines: 25