[Qgis-developer] Python plugin - Path to gdal
kimaidou
kimaidou at gmail.com
Wed Nov 10 09:04:19 EST 2010
Hi qgis dev,
I am still working on my python plugin. Now, thanks to Carson and Barry, my
UI is running smoothly.
Now I am working on the core code.
I would like to use Gdal to perform a gdal_translate on some selected raster
layer.
I have no idea how I can find the path of the gdal binary used by Qgis. Of
course I need an OS independant method.
I tried to read the GdalTool plugin code, but woow, it is a bit too
complicated for me rigth now. E.g, I have seen there is a function :
# Retrieves GDAL binaries location
def getGdalPath():
settings = QSettings()
return settings.value( "/GdalTools/gdalPath", QVariant( "" ) ).toString()
But I am not sure it will work if run from another plugin (especially if
GdalTool is not installed/active ).
Thanks in advance for helping me,
Kimaidou
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/qgis-developer/attachments/20101110/f4332c24/attachment-0001.html
More information about the Qgis-developer
mailing list