[comp.sys.mac.hardware] Where does video on the Mac II get its memory?

allon@eng.umd.edu (Allon Stern) (03/26/90)

The other day, a friend and I were debating where the mac's video memory
(screen buffer?) resides.  I always thought that the memory is on the
video card, but my friend maintains that it gets taken from the main memory,
and that you can save memory by switching to 2-color mode.  So, which is it?

How about the Mac Plus and older, and the Portable which has a built - in
screen?  Thanks.

                             - -= Allon =- -

-------------------------------------------------------------------------------
   This is a test of the emergency signature system.  Were this an actual
   signature, you would see amusing mottos, disclaimers, a zillion net
   addresses, or edifying philisophical statements.  This is only a test.
-------------------------------------------------------------------------------

dale@bcm.tmc.edu (Dale A. Samuelsen) (03/27/90)

In article <1990Mar26.100104.552@eng.umd.edu> allon@eng.umd.edu (Allon 
Stern) writes:
> The other day, a friend and I were debating where the mac's video memory
> (screen buffer?) resides.  I always thought that the memory is on the
> video card, but my friend maintains that it gets taken from the main 
memory,
> and that you can save memory by switching to 2-color mode.  So, which is 
it?

The answer is "It Depends".  If the Mac II is a Mac IIci, then the video 
interface is built into the mother board and "borrows" some of the RAM to 
use as the video memory.   In this case your friend is accurate in his 
assertion that you can save RAM memory by switching to 2 color mode.

In the case of any other Mac II products, the video memory is on the video 
interface card and RAM memory will not be effected by a switch to 2 color 
(Black & White) mode.

Dale

Dale A. Samuelsen
Baylor College of Medicine
dale@bcm.tmc.edu
--Any opinions expressed are mine alone and do not necessarily represent 
those of Baylor College of Medicine.

henry@chinet.chi.il.us (Henry C. Schmitt) (03/27/90)

In article <367@gazette.bcm.tmc.edu> dale@bcm.tmc.edu (Dale A. Samuelsen) writes:
>In article <1990Mar26.100104.552@eng.umd.edu> allon@eng.umd.edu (Allon 
>Stern) writes:
>> and that you can save memory by switching to 2-color mode.
>
>The answer is "It Depends".  If the Mac II is a Mac IIci, then the video 
>interface is built into the mother board and "borrows" some of the RAM to 
>use as the video memory.   In this case your friend is accurate in his 
>assertion that you can save RAM memory by switching to 2 color mode.
>
Please note that simply going to the Monitors cdev and changing to 2
colors (or greys) will _not_ save you any memory, the video memory
is allocated at startup and cannot be changed without rebooting.

The way to do this is 1) open the monitors cdev, 2) hold down the
option key and hit the options button (so much for intuitive), 3)
choose the maximum colors you want memory allocated for, 4) reboot.

I find many people have the mistaken idea that changing the number
of colors at the top level of the Monitors cdev will allocate or
deallocate memory for video.
-- 
  H3nry C. Schmitt     | CompuServe: 72275,1456  (Rarely)
                       | GEnie: H.Schmitt  (Occasionally)
 Royal Inn of Yoruba   | UUCP: Henry@chinet.chi.il.us  (Best Bet)

meuchen@grad2.cis.upenn.edu (Paul Eric Menchen) (03/28/90)

In article <1990Mar27.035008.2705@chinet.chi.il.us> henry@chinet.chi.il.us (Henry C. Schmitt) writes:
>In article <367@gazette.bcm.tmc.edu> dale@bcm.tmc.edu (Dale A. Samuelsen) writes:
>>In article <1990Mar26.100104.552@eng.umd.edu> allon@eng.umd.edu (Allon 
>>Stern) writes:
>>> and that you can save memory by switching to 2-color mode.
>>
...
>Please note that simply going to the Monitors cdev and changing to 2
>colors (or greys) will _not_ save you any memory, the video memory
>is allocated at startup and cannot be changed without rebooting.
>
>The way to do this is 1) open the monitors cdev, 2) hold down the
>option key and hit the options button (so much for intuitive), 3)
>choose the maximum colors you want memory allocated for, 4) reboot.
>
>I find many people have the mistaken idea that changing the number
>of colors at the top level of the Monitors cdev will allocate or
>deallocate memory for video.
...
By changing to two bit mode you won't get any more memory for system
system use from the video card, but you can save memory. Let me
explain.

First, an example (with an explanation to follow): I have a Mac II, 8
bit Apple video card, 1 meg memory (don't laugh, please). If I try to
execute Illustrator 88 in 8 bit mode, I get a "Not enough memory ..."
message. Putting it in 4 bit mode will allow it to run if I'm not
running Master Juggler.  Master Juggler also takes memory, as do other
CDEVs and INITs I have running.  When I have these running, I have to
change to 2 bit mode to get Illustrator 88 to run.  I can try to
execute Illustrator in 8 bit mode, get a "Not enought memory ..."
message, then change the pixel depth with the Control Panel to some
lower value and then run Illustrator successfully, without ever
rebooting.

Why? To start, a reboot is not necessary for the Control Panel
settings to take effect in terms of operation of the video card.  If
it were, it would be impossible to change to 256 colors after strating
up in 2 bit mode. I, however, do this all the time (o.k. every now and
then).

Further, while the video memory is independent of the main memory,
many (most?) programs use main memory for video purposes. If you want
to generate a pixel map/image/whatever, you'll do it in main memory.
Illustrator can generate a screen preview of whatever you're working
on. To do this it uses main memory. Illustrator generates the image
based on the pixel depth of the screen, and of course 2-bit images
take less memory than 8-bit images. If you have a program to display
GIF images, it uses main memory to decompress the image, and if the
program is smart it will only allocate enough memory based on the
pixel depth of your display.  

Just think about when you have multiple windows on the screen. You
may not be able to see part of one window, so it's not currently
taking any video memory, but as soon as you move the window covering
it to see what was covered, there it is. A write from main memory to
the video memory has occured.

Just about everything you see on the screen exists in main memory
somewhere in one form or another. There are a few exceptions to this,
but not many (one that comes to mind occurs in GIFfer, and it tells you
when this occurs.)

Paul Eric Menchen
meuchen@grad1.cis.upenn.edu

henry@chinet.chi.il.us (Henry C. Schmitt) (03/28/90)

In article <22344@netnews.upenn.edu> meuchen@grad1.cis.upenn.edu (Paul Eric Menchen) writes:
>In article <1990Mar27.035008.2705@chinet.chi.il.us> henry@chinet.chi.il.us (Henry C. Schmitt) writes:
>>In article <367@gazette.bcm.tmc.edu> dale@bcm.tmc.edu (Dale A. Samuelsen) writes:
>>>In article <1990Mar26.100104.552@eng.umd.edu> allon@eng.umd.edu (Allon 
>>>Stern) writes:
>>>> and that you can save memory by switching to 2-color mode.
>>>
>>> [Reference to Mac IIci on board video deleted by person replying
>>>  to my article.]
>...
>>Please note that simply going to the Monitors cdev and changing to 2
>>colors (or greys) will _not_ save you any memory, the video memory
>>is allocated at startup and cannot be changed without rebooting.
>...
>By changing to two bit mode you won't get any more memory for system
>system use from the video card, but you can save memory. Let me
>explain.
>
Yes, you are correct in almost all instances.  However the article I
was replying to was discussing the Mac IIci on board video.  You
mangaed to overlook this when reading the message, then cut it out
of your reply.

To summarize:  we are both correct.  With any MacII NuBus Video
card, changing the number of colors displayed does not change the
amount of memory available to programs and the system.  With the Mac
IIci built-in video (the only non-NuBus Mac II video that I'm aware
of) more memory can be made available to the system by appropriately
twiddling the Monitors cdev (see my previous message for details)
and rebooting.

-- 
  H3nry C. Schmitt     | CompuServe: 72275,1456  (Rarely)
                       | GEnie: H.Schmitt  (Occasionally)
 Royal Inn of Yoruba   | UUCP: Henry@chinet.chi.il.us  (Best Bet)