Path: utzoo!attcan!uunet!lll-winken!ames!sgi!msc@ramoth.SGI.COM From: msc@ramoth.SGI.COM (Mark Callow) Newsgroups: comp.windows.news Subject: retained canvases - application writers please read Keywords: portability Message-ID: <24631@sgi.SGI.COM> Date: 11 Jan 89 03:29:40 GMT Sender: daemon@sgi.SGI.COM Organization: Silicon Graphics, Inc., Mountain View, CA Lines: 36 Almost every NeWS application that I have seen that uses retained canvases fails to respond correctly to /Damaged events. The most common problem is that the program paints into an unmapped retained canvas then maps the canvas. The program expects mapping to cause its bits to be transferred to the screen from the retained buffer. However to quote the NeWS manual Section 2.2, Page 14 "All programs have to cope with damage and must be able to reconstruct the damaged part" ... "retained canvases are purely a performance enhancement". and from Section 11.3, Page 120 "For color displays the cost of retaining canvases is often prohibitive". And to quote from "The NeWS Book" (not yet published) "Retained canvases are purely a performance enhancement. A server may choose to stop supporting retained canvases at any time, such as when running out of memory. Programs must always be ready to cope with damage." The Silicon Graphics 4Sight (NeWS) server, when running in RGB mode (the default mode on most of our systems) chooses not to support retained canvases. This is because of the memory cost of 24-bit deep pixels especially given our fast rendering speed. Therefore there may not be a retained buffer so the program had better be able to respond to damage when it maps a "retained" canvas. Those that don't will not work on a large class of machines running NeWS. Application writers please take note. -- -Mark