« Origami | Main | Jobs I Couldn't Keep (II) »

March 09, 2006

XPenguins on MacOS X

Q: I came across this program (xpenguins) and tried it using the X11 program in /Applications/Utilities but it doesn't work.

A: The problem is that the program wants to write to the root window and Apple's X11 doesn't really have a root window (the X-based windows are using the underlying Aqua environment instead of an xroot window). So instead, you need to specify a window so that the penguins can perform. Any window that draws a canvas should do (i.e. not an xterm). For my example, I am going to use xearth. Note that when xwininfo asked, I clicked in the xearth window. This returns heaps of information but we only need the window id...

toffee$ xearth -noroot &
[1] 10746
toffee$ xwininfo
xwininfo: Please select the window about which you
    would like information by clicking the
    mouse in that window.
xwininfo: Window id: 0x800005 "xearth"
    Absolute upper-left X: 0
    ...
    Corners: +0+44 -1168+44 -1168-494 +0-494
    -geometry 512x512+0+22
toffee$ xpenguins --all -s -n 10 -id 0x800005

And the result?

2006-03-08--xpenguins.png

Posted by Ozguru at March 9, 2006 06:00 AM