Re: Writing on X without X device (!) [message #14589 is a reply to message #14553] |
Fri, 12 March 1999 00:00   |
David Foster
Messages: 341 Registered: January 1996
|
Senior Member |
|
|
> Andr� L. Bel�m (abelem@awi-bremerhaven.de) writes:
>
>> I'm writing a procedure to process satellite images on a map projection.
>> I extract the image information from a jpeg file, and then I make some
>> transformations and write the result on GIF.
>>
>> But I would like to run all in batch mode because this take time and
>> must be run every night.
>> The problem is: how to run IDl in batch mode and use all tv, tvlct,
>> map_image, and others ??
Andre -
There is another alternative besides the Z-buffer, if you are on a
UNIX system, which would not require you to modify existing code.
You can use xvfb which is a "virtual frame-buffer", part of X11R6.
If you are using a different version of X, you can download this from:
ftp://ferret.wrc.noaa.gov/pub/special_requests/xvfb/solaris/ X11R6/bin.tar.gz
You don't have to enable this version of X, you can just use the xvfb
binary if you like. But it does need other files within the
distribution.
Info available at:
http://tmap.pmel.noaa.gov/home/ferret/FAQ/#xvfb
http://hegel.ittc.ukans.edu/topics/linux/man-pages/man1/Xvfb .1.html#toc7
This is quite easy to set up. I use it to allow me to run DBMSCOPY in
batch mode overnight, as a cron job.
Here's an excerpt from a document I wrote on it's use:
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- =-=-=-=-=-=
Since this program is an X client, it requires the presence of an X
server,
making it problematic to automate this process using CRON.
The X version X11R6 was downloaded via anonymous ftp from:
ftp://ferret.wrc.noaa.gov/pub/special_requests/xvfb/solaris/ X11R6/bin.tar.gz
Then it's just a matter of starting the virtual frame buffer program
on <HOST> to create the virtual display #1:
/usr/X11R6/bin/Xvfb :1 -screen 0 1152x900x8 &
Then within the script that performs <desired batch operations>
the following line sends graphics output to DISPLAY 1, the virtual frame
buffer we just started:
set DISPLAY=:1.0 ; export DISPLAY
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- =-=-=-=-=-=
Hope this helps.
Dave
--
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~
David S. Foster Univ. of California, San Diego
Programmer/Analyst Brain Image Analysis Laboratory
foster@bial1.ucsd.edu Department of Psychiatry
(619) 622-5892 8950 Via La Jolla Drive, Suite 2240
La Jolla, CA 92037
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~
|
|
|