Dialog Box: Raster (Bitmap) Files [ File Menu]
--Windows/Linux Only ----------
This command can write files in four different formats (File type ): Windows device-independent format (.BMP); PC-Paintbrush (.PCX); Tag-image-format (.TIF); and Portable Network Graphics (.PNG) files.
If the Compress .BMP box is checked, 4- and 8-bit .BMP files are compressed; 1- and 24- bit .BMP files are never compressed. Owing to a system bug, compression of 4-bit .BMP files may not work when banding is used (see below). TIF files are compressed with run-length encoding, which is one of the required formats under the TIFF 6.0 standard. However, some applications may not support this type of compression, or may reject .TIF files for other reasons.
--Macintosh only---------
This command can write files in the Portable Network Graphics (.PNG) format. The PICT Files option (File menu) can also write raster or bitmap files, in the PICT format.
--End Windows/Macintosh only----
See Selection of File Format below for information on choosing the format.
Each one of these may be either black and white or color. If black and white, the pixel size is 1-bit. For color files the pixel size is based on the current screen; 4-bit for standard VGA or other 4-bit display, 8-bit for 256-color display, and 24-bit for 16- or 24-bit display.
The images will look much the same as a screen image, except that for black-and-white files there is a choice of coarse or fine dot patterns to represent gray shades, as for printing and metafiles (see the Print dialog in the File menu). Fine patterns are appropriate for small images which will not be reproduced photographically, or for images which will be shown on the screen only; coarse patterns mimic halftone screens used in printing, and generally reproduce better photographically, especially when the image is reduced in size. Note that this coarse/fine setting is the same as that in the Print and Metafiles dialogs in the File menu.
See for details of the frame and frame units.
Maximum memory . Windows and Macintosh use virtual memory , which means that it pretends that a hard disk can be used in place of actual hardware memory chips. For some applications this is useful, but when writing raster files it often results in "disk thrashing", or constant reading and writing of data to the hard disk.
SHAPE is capable of imaging and writing raster files in segments or bands to avoid this problem. This requires repeating the entire drawing process for each band, but this usually is much faster than the reading/writing to disk involved in using virtual memory. To do this requires knowing how much actual chip memory is available. Unfortunately, at present Windows does not provide this information in a way that can be used for both 16- (standard Windows 3.1) and 32-bit (Windows NT) systems. Thus the user may need to determine this by trial and error using the Maximum memory parameter.
When the Maximum memory parameter is set to zero, SHAPE will simply ask the system for a block of memory large enough to image the entire drawing at once. This amount of memory is printed out in the dialog which appears after starting the raster imaging: "nnnn bytes required, mmmm bytes available - will require 1 bands". If this amount of memory is greater than the amount of chip memory available, Windows will use virtual memory, which is typically manifested by constant running of the hard disk for long periods. If you change the Maximum memory to some amount smaller than nnnn (say half), SHAPE will only request this amount of memory from the system, and virtual memory may not come into play. A Maximum memory setting should be good for a given session, regardless of the size of the raster file; larger files will use more bands. However, the amount of memory available may depend on whether other applications are active.
The amount of virtual memory is determined by the available space on the hard disk. If this is insufficient, SHAPE will automatically use bands, but since virtual memory is being used, it may still be advantageous to use a Maximum memory value which will increase the number of bands.
Testing has suggested that a Maximum memory setting of about 1 mb (1000 kb) may be the optimum, at least for simple drawings.
Note that from V5.0.1 SHAPE uses Windows system routines to draw bitmaps, rather than its own assembly-language routines, which were used in DOS versions and V5.0 for Windows. The only effect of this from the user's point of view is to remove complete freedom in determining the pixel size of color bitmaps.
Selection of File Format. The choice of format depends first of all on what formats are supported by the target software (paint program; publishing program; etc.). Beyond this the first choice should be PNG. For Windows the second choice should be PCX, and then TIF or BMP depending of what is supported and how much memory or disk space is available. For Macintosh, the only choice besides PNG is PICT , which is usually not as compact, but this may depend on the Macintosh operating system.
As of 1997, the preferred graphics file types for the internet were GIF and JPEG. However, GIF uses the LZW compression scheme copyrighted by Unisys Corp., which in principle charges a license fee for every application using it. JPEG files are compact but involve losses and degradation of the image and are thus not suitable for SHAPE files.
The PNG format is intended to be a replacement for GIF, and in fact is superior to most other formats, being lossless and giving very good compression for the type of images generated by SHAPE (although 3D images do not compress as well as standard-mode images). Essentially all major software vendors have subscribed to the PNG convention and releases from 1998 onward should support it.
Most TIF files also use LZW compression, but SHAPE does not use this type of compression because of the copyright problem. The run-length-encoding which SHAPE does use is supposed to be supported by all TIF readers, but in fact some do not support it, and this algorithm does not work well for 24-bit (RGB) images.
There are dozens of raster graphics formats and it will never be possible for SHAPE to support all of them. SHAPE users who work with raster files should consider investing in a conversion program - there are many such programs which are not expensive. Hijaak, by Inset Systems, handles a great many raster, metafile and vector formats. The PNG home page (www.cdrom.com/pub/pnp) has links to many shareware and conventional commercial conversion packages.