Michael Barton wrote: > I'm going to try this as soon as I can steal a bit of time. I'm > somewhat uncertain how to get the initial PNG for GRASS_PNG_READ. > > I can create a dummy temp map using r.mapcalc and then save it to a > PNG using r.out.png. But I need to make sure that it's background is > transparent so that the final composite can overlay whatever is in the > map display. Any suggestion for how I do that?
You don't actually need to create an initial image; if the file doesn't exist, any GRASS_PNG_READ=TRUE setting will be silently ignored. If the file does exist, the dimensions and depth must match the values of $GRASS_WIDTH, $GRASS_HEIGHT and $GRASS_TRUECOLOR. You can create a blank image with "d.frame -e" or "d.erase -f". If GRASS_TRANSPARENT=TRUE, the image will be transparent, otherwise it will be filled with $GRASS_BACKGROUNDCOLOR. This works both with direct rendering and the PNG driver. Note that "d.erase" alone is equivalent to "d.erase color=white". There isn't any way to clear a portion of the screen to transparent, only the entire screen. -- Glynn Clements <[EMAIL PROTECTED]> _______________________________________________ grass-dev mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/grass-dev
