[GRASS5] PNG driver problem

Glynn Clements glynn.clements at virgin.net
Wed Aug 25 17:46:46 EDT 2004


David Piasecki wrote:

> Or perhaps the quickest solution is to simply change the environment 
> variable to TRUE just before a display command.

That won't work. One process can't change the environment of another. 
Whatever values those variables have at the point that the PNG driver
is started (i.e. "d.mon start=PNG") will persist for the lifetime of
the driver process.

> However, I see that 
> Client.c simply has a write_image() call on ClientClose() if the 
> AUTO_WRITE environment variable had been set. Is it that simple to 
> create a new binary, something like d.write_png? It could simply call 
> write_image().

That won't work either. Each monitor runs as a separate process. 
Clients (d.* programs) interface with the monitors using the raster
library, which connects to the driver process via the Unix-domain
socket in /tmp/grass-<username>.

-- 
Glynn Clements <glynn.clements at virgin.net>




More information about the grass-dev mailing list