1

There's a plugin called "create mask" for qGIS and trying out some simple scripting from the Python console.

I would like to call it after I select the vector features I want, then do more related tasks afterwards. So, how does one run "create mask" from the console?

1 Answer 1

1

I have no solution for doing this in python (you can easily call plugins with Sextante support, but i don't know how to call qgis plugins in general), but i highly advise you to take a look at the Sextante toolbox and its modeler. The SAGA extension for Sextante has a similar Mask creation function (Create Grid Mask). Using the Sextante modeler you can build processing chains without any script use.

9
  • @ Thanks for suggesting this. I'm trying it out but couldn't find this "create grid mask" from the SAGA extension of Sextante. Am I supposed to install anything else?
    – n1kn0k
    Commented Mar 7, 2013 at 22:59
  • If you installed Sextante and SAGA and have correctly linked the SAGA-Install dir in the Sextante options, then the function should appear as "Grid Masking". Is this what you want? I am not so sure anymore and the word mask has been used in many different contexts.
    – Curlew
    Commented Mar 7, 2013 at 23:02
  • I can see that now "Grid Masking" but I'm encountering problems with SAGA and Ubuntu 12.04. An error pops out: "It seems that SAGA is not correctly installed in your system. Please install it before running SAGA algorithms." When I ran saga_cmd, I found: error: Library does not contain executable modules [librecreations_games.so]
    – n1kn0k
    Commented Mar 8, 2013 at 11:56
  • did you compile it yourself or use a pre-compiled binary? On linux Sextante should be able to automatically determine your saga install folder, therefore there is a problem with your saga install. Download the latest src and compile it / install systemwide sourceforge.net/projects/saga-gis/files/SAGA%20-%202.0
    – Curlew
    Commented Mar 8, 2013 at 12:09
  • i used a package i found from the ubuntu Precise repos, version 2.07b
    – n1kn0k
    Commented Mar 8, 2013 at 12:54

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.