Re: [Qgis-user] Using/visualizing 3D data (Z values)

2012-10-17 Thread David Fawcett
Thanks for your response.  I am sure that it is there, but when I try
to import pyqt or pyqt4 I get the standard message about the module
not existing.  This is the case both in a normal shell or in the QGIS
Python window.

For visvis, when I try app = vv.use(), the backend is not detected.

David.

On Wed, Oct 17, 2012 at 12:55 AM, gene martin.lal...@gmail.com wrote:
 PyQt4 is present in the QGIS versions of William to be used in the Python
 console, so, automatically you have a backend.



 --
 View this message in context: 
 http://osgeo-org.1560.n6.nabble.com/Using-visualizing-3D-data-Z-values-tp4126375p5009181.html
 Sent from the Quantum GIS - User mailing list archive at Nabble.com.
 ___
 Qgis-user mailing list
 Qgis-user@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/qgis-user
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Using/visualizing 3D data (Z values)

2012-10-17 Thread gene
it is a problem of PATH

*1) in the shell:*
If you read the Read Me.rtf accompanying QGIS, the procedure is specified:
/The PyQt programs are included to compile UI and resource files for
plugins.  To use them, set these in your shell environment (you can add it
to your ~/.bash_profile if you like):

export PATH=/Applications/QGIS.app/Contents/MacOS/bin:$PATH
export PYTHONPATH=/Applications/QGIS.app/Contents/Resources/python

If you already have something in PYTHONPATH, add it instead with:

export
PYTHONPATH=/Applications/QGIS.app/Contents/Resources/python:$PYTHONPATH

Note that QGIS.app MUST be installed in /Applications and must not be
renamed for pyuic4 to work (it has a hardcoded path in it)./

After that, you can use PyQt4 in the shell 

 import PyQt4
 PyQt4.__file__
'/Applications/QGIS.app/Contents/MacOS/../Resources/python/PyQt4/__init__.pyc'


*2) In the console of QGIS*, 
This is not normal because the console itself is written in PyQt4
1) with QGIS 1.8
 import   PyQt4:
 PyQt4.__file__
'/Applications/*QGIS.app*/Contents/MacOS/../Resources/python/PyQt4/__init__.pyc'
2) with QGIS dev:
 import   PyQt4
 PyQt4.__file__
'/Applications/*QGIS_2.0-dev_SnoLeo.app*/Contents/MacOS/../Resources/python/PyQt4/__init__.pyc'






--
View this message in context: 
http://osgeo-org.1560.n6.nabble.com/Using-visualizing-3D-data-Z-values-tp4126375p5009339.html
Sent from the Quantum GIS - User mailing list archive at Nabble.com.
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Using/visualizing 3D data (Z values)

2012-10-17 Thread David Fawcett
Thank you very much for your help.  Indeed, it was the PATH/PYTHONPATH issue.

I think that when I installed QGIS last time, I was in a rush and
didn't think that I would need the Python support.  I decided to
reinstall QGIS and then I found the same README.

I am excited to play with visvis.

David.

On Wed, Oct 17, 2012 at 10:12 AM, gene martin.lal...@gmail.com wrote:
 it is a problem of PATH

 *1) in the shell:*
 If you read the Read Me.rtf accompanying QGIS, the procedure is specified:
 /The PyQt programs are included to compile UI and resource files for
 plugins.  To use them, set these in your shell environment (you can add it
 to your ~/.bash_profile if you like):

 export PATH=/Applications/QGIS.app/Contents/MacOS/bin:$PATH
 export PYTHONPATH=/Applications/QGIS.app/Contents/Resources/python

 If you already have something in PYTHONPATH, add it instead with:

 export
 PYTHONPATH=/Applications/QGIS.app/Contents/Resources/python:$PYTHONPATH

 Note that QGIS.app MUST be installed in /Applications and must not be
 renamed for pyuic4 to work (it has a hardcoded path in it)./

 After that, you can use PyQt4 in the shell

 import PyQt4
 PyQt4.__file__
 '/Applications/QGIS.app/Contents/MacOS/../Resources/python/PyQt4/__init__.pyc'


 *2) In the console of QGIS*,
 This is not normal because the console itself is written in PyQt4
 1) with QGIS 1.8
 import   PyQt4:
 PyQt4.__file__
 '/Applications/*QGIS.app*/Contents/MacOS/../Resources/python/PyQt4/__init__.pyc'
 2) with QGIS dev:
 import   PyQt4
 PyQt4.__file__
 '/Applications/*QGIS_2.0-dev_SnoLeo.app*/Contents/MacOS/../Resources/python/PyQt4/__init__.pyc'






 --
 View this message in context: 
 http://osgeo-org.1560.n6.nabble.com/Using-visualizing-3D-data-Z-values-tp4126375p5009339.html
 Sent from the Quantum GIS - User mailing list archive at Nabble.com.
 ___
 Qgis-user mailing list
 Qgis-user@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/qgis-user
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Using/visualizing 3D data (Z values)

2012-10-16 Thread gene
Waiting for Globe, a solution to extract the z values of 3D shapefiles is to
use ogr or shapely (see in qgis-developer 
http://osgeo-org.1560.n6.nabble.com/Re-Qgis-user-Using-visualizing-3D-data-Z-values-td5004272.html
http://osgeo-org.1560.n6.nabble.com/Re-Qgis-user-Using-visualizing-3D-data-Z-values-td5004272.html
 
, 
http://osgeo-org.1560.n6.nabble.com/visualizing-3D-data-Z-values-or-data-with-z-attribute-a-solution-td5005360.html
http://osgeo-org.1560.n6.nabble.com/visualizing-3D-data-Z-values-or-data-with-z-attribute-a-solution-td5005360.html
 
). 

After  you can use matplotlib or other Python modules like  * Visvis
http://code.google.com/p/visvis/  * to visualize the data in 3D:
http://osgeo-org.1560.n6.nabble.com/file/n5009086/qgisvisvissurfbok.png 
(see also, with  http://code.google.com/p/visvis/wiki/Screenshots
http://code.google.com/p/visvis/wiki/Screenshots  )
This solution also applies to layers with z attribute.

The full explanation of the processing is given, in French, at  QGIS,
représentation 3D des couches vectorielles (shapefiles dits 3D ou shapefiles
avec attributs z) avec avec les modules Python Matplotlib ou Visvis à partir
de la console Python
http://www.portailsig.org/content/qgis-representation-3d-des-couches-vectorielles-shapefiles-dits-3d-ou-shapefiles-avec-attrib
  





--
View this message in context: 
http://osgeo-org.1560.n6.nabble.com/Using-visualizing-3D-data-Z-values-tp4126375p5009086.html
Sent from the Quantum GIS - User mailing list archive at Nabble.com.
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Using/visualizing 3D data (Z values)

2012-10-16 Thread David Fawcett
Gene,

Your email and posts got me inspired to install visvis.

I am running Qgis 1.8 on OSX using William's installers at
kyngchaos.com.  By default, I don't have a GUI toolkit installed for
the backend.  Does anyone have any suggestions on the best way to get
one installed without conflicting with QGIS or other applications?

Thanks,

David.

On Tue, Oct 16, 2012 at 12:27 PM, gene martin.lal...@gmail.com wrote:
 Waiting for Globe, a solution to extract the z values of 3D shapefiles is to
 use ogr or shapely (see in qgis-developer
 http://osgeo-org.1560.n6.nabble.com/Re-Qgis-user-Using-visualizing-3D-data-Z-values-td5004272.html
 http://osgeo-org.1560.n6.nabble.com/Re-Qgis-user-Using-visualizing-3D-data-Z-values-td5004272.html
 ,
 http://osgeo-org.1560.n6.nabble.com/visualizing-3D-data-Z-values-or-data-with-z-attribute-a-solution-td5005360.html
 http://osgeo-org.1560.n6.nabble.com/visualizing-3D-data-Z-values-or-data-with-z-attribute-a-solution-td5005360.html
 ).

 After  you can use matplotlib or other Python modules like  * Visvis
 http://code.google.com/p/visvis/  * to visualize the data in 3D:
 http://osgeo-org.1560.n6.nabble.com/file/n5009086/qgisvisvissurfbok.png
 (see also, with  http://code.google.com/p/visvis/wiki/Screenshots
 http://code.google.com/p/visvis/wiki/Screenshots  )
 This solution also applies to layers with z attribute.

 The full explanation of the processing is given, in French, at  QGIS,
 représentation 3D des couches vectorielles (shapefiles dits 3D ou shapefiles
 avec attributs z) avec avec les modules Python Matplotlib ou Visvis à partir
 de la console Python
 http://www.portailsig.org/content/qgis-representation-3d-des-couches-vectorielles-shapefiles-dits-3d-ou-shapefiles-avec-attrib





 --
 View this message in context: 
 http://osgeo-org.1560.n6.nabble.com/Using-visualizing-3D-data-Z-values-tp4126375p5009086.html
 Sent from the Quantum GIS - User mailing list archive at Nabble.com.
 ___
 Qgis-user mailing list
 Qgis-user@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/qgis-user
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Using/visualizing 3D data (Z values)

2012-10-16 Thread gene
PyQt4 is present in the QGIS versions of William to be used in the Python
console, so, automatically you have a backend.



--
View this message in context: 
http://osgeo-org.1560.n6.nabble.com/Using-visualizing-3D-data-Z-values-tp4126375p5009181.html
Sent from the Quantum GIS - User mailing list archive at Nabble.com.
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-user


[Qgis-user] Using/visualizing 3D data (Z values)

2011-12-05 Thread Paul Lens

Hi all,

1. I made a TIN surface, using the interpolation plugin, from a point 
shapefile (with ALTITUDE field) and  3D line shapefiles. I lost time 
trying to extract the relevant lines from the line shapefiles without 
loosing the 3D information (Z values of the nodes).
If I remember well, I first used Merge Layers from the mmqgis plugin, 
and it kept the Z information. Than, I used the Intersection command in 
the Vector menu, and the Z information was lost. Finally, after manually 
selecting the relevant lines and using save as, I got the expected 3D 
line shapefile keeping the Z values.
Is this loss of Z information a known limitation of the gdal vector 
commands in QGIS (vector menu) and is this limitation affecting all 
these commands? Or did I do something wrong?


2. In a second step, I wanted to be able to easily see (through labeling 
a Z field) or ask (with the identify command) those Z values from the 3D 
lines, so as to fine tune the interpretation of the topography.
Again the gdal tool (in Vector menu) Node Extraction lost all Z 
information.
Is there a workaround to create a point shapefile with a Z field? Or, at 
least, to keep the Z values in a point shapefile, rasterize it so as to 
be able to visualize the Z value using  the Identify command on the 
raster?


Thanking all the developers for this wonderful program,

--
Paul

___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Using/visualizing 3D data (Z values)

2011-12-05 Thread Marco Hugentobler














Hi Paul

Unfortunately, the current geometry system does not handle z- and
m-values in a sound way.
Some tools consider z and others don't. M-values are even more difficult
as they cannot be accessed by the QGIS API (z-coordinates can be read by
parsing the binary format of the geometry).

An overhaul of the geometry system is planned for version 2.

Regards,
Marco

On 05.12.2011 10:42, Paul Lens wrote:

 Hi all,

 1. I made a TIN surface, using the interpolation plugin, from a point
 shapefile (with ALTITUDE field) and  3D line shapefiles. I lost time
 trying to extract the relevant lines from the line shapefiles without
 loosing the 3D information (Z values of the nodes).
 If I remember well, I first used Merge Layers from the mmqgis
 plugin, and it kept the Z information. Than, I used the Intersection
 command in the Vector menu, and the Z information was lost. Finally,
 after manually selecting the relevant lines and using save as, I got
 the expected 3D line shapefile keeping the Z values.
 Is this loss of Z information a known limitation of the gdal vector
 commands in QGIS (vector menu) and is this limitation affecting all
 these commands? Or did I do something wrong?

 2. In a second step, I wanted to be able to easily see (through
 labeling a Z field) or ask (with the identify command) those Z values
 from the 3D lines, so as to fine tune the interpretation of the
 topography.
 Again the gdal tool (in Vector menu) Node Extraction lost all Z
 information.
 Is there a workaround to create a point shapefile with a Z field? Or,
 at least, to keep the Z values in a point shapefile, rasterize it so
 as to be able to visualize the Z value using  the Identify command
 on the raster?

 Thanking all the developers for this wonderful program,




--
Dr. Marco Hugentobler
Sourcepole -  Linux   Open Source Solutions
Churerstrasse 22, CH-8808 Pfäffikon SZ, Switzerland
marco.hugentob...@sourcepole.ch http://www.sourcepole.ch
Technical Advisor QGIS Project Steering Committee


___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-user