[UNIX][VM] Display depths (was: Re: "Emulating" a PDA)

Bert Freudenberg bert at isg.cs.uni-magdeburg.de
Thu Oct 19 08:06:56 UTC 2000


On Wed, 18 Oct 2000, Lalo Martins wrote:

> Also, my Squeak (2.9 - 2774) doesn't offer me depth 1. Did I do
> something wrong?

The Unix VM currently only provides depths 8, 16, and 32. See sqXWindow.c
You would need to code more copy functions - currently four of them:
copyImage1To8(), copyImage1To16(), copyImage1To24(), copyImage1To32()

Besides, this might be an area of the Unix VM that is worth working on
anyway. For example, I run X in 24 bpp. When I switch Squeak to depth 8,
the VM extends this 1 byte per pixel to 4 bytes per pixel so 4 times the
amount of data necessary is sent to the X server. Which doesn't matter if
using xshm on your local display, but this is one reason why working
remotely is so slow. It would be great if reducing Squeak's display depth
would result in less data sent over the wire. My X server (XFree86 4,
NVidia) even allows all depths for pixmaps (although all visuals are 24
bpp):

bert.balloon ~ > xdpyinfo
supported pixmap formats:
    depth 1, bits_per_pixel 1, scanline_pad 32
    depth 4, bits_per_pixel 8, scanline_pad 32
    depth 8, bits_per_pixel 8, scanline_pad 32
    depth 15, bits_per_pixel 16, scanline_pad 32
    depth 16, bits_per_pixel 16, scanline_pad 32
    depth 24, bits_per_pixel 32, scanline_pad 32

I think 1 bpp is supported in every X server? If this was supported in
Squeak, and I really needed to work remotely, I could set Squeak's depth
to 1 and possibly be even faster than VNC ;^)

-- Bert






More information about the Squeak-dev mailing list