2

In the process of learning GRASS, I am finding that I can learn many of the command-line methods that I need for scripting tasks from using the wxGUI, as it conveniently shows most of the underlying commands that it runs. This has not turned out to be the case for setting the opacity of layers. A little Googling turned up a module called g.pnmcomp, which may be responsible for controlling layer opacity. Unfortunately, that module appears not to be intended for end-users and I have not found documentation that is sufficient for me to make use of it; I'd need to know how to generate the PPM/PGM pairs that it stacks, at least.

There to not appear to be arguments for opacity in d.rast or d.vect, and I suspect that it's the png or tif driver that would actually be handling the opacity of layers. That's the background, but my question is quite simple. How can I set the opacity of layers in maps created via the command line?

asked Oct 3, 2013 at 15:17
2
  • I think the short answer to your question is that you can't set the opacity for 'd.vect' and 'd.rast' from the command-line. It seems only possible from the wxGUI. Commented Oct 4, 2013 at 8:38
  • The way around is r.blend and r.composite. See also the following related thread in the grass-user mailing list: lists.osgeo.org/pipermail/grass-user/2013-October/069028.html Commented Oct 14, 2013 at 11:12

1 Answer 1

2

I used already (Python) scripts that uses GRASS commands, namely d.mon, d.vect and d.rast, to create programmatically maps which works straightforward.

But as user dmci already stated there seems to be no way to set the opacity for a layer.

answered Oct 7, 2013 at 17:10

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.