Bug report #11952
Network analysis graph empty
Status: | Closed | ||
---|---|---|---|
Priority: | High | ||
Assignee: | - | ||
Category: | Analysis library | ||
Affected QGIS version: | 2.6.0 | Regression?: | No |
Operating System: | Windows | Easy fix?: | No |
Pull Request or Patch supplied: | No | Resolution: | |
Crashes QGIS or corrupts data: | No | Copied to github as #: | 20160 |
Description
When building a graph using the network analysis library, I get (depending on the shapefile) a empty graph (no nodes or edges), even when there are features on the layer.
I attach two files, that should be identical as seen from the network analysis library, but they produce widely different results. For example, run:
layer = iface.activeLayer() director = QgsLineVectorLayerDirector( layer, -1, '', '', '', 3 ) properter = QgsDistanceArcProperter() director.addProperter( properter ) builder = QgsGraphBuilder( layer.crs() ) tiedPoints = director.makeGraph( builder, [] ) graph = builder.graph() vn = graph.vertexCount() print(u"the graph has"+str(vn)+u" points")
on both layers(of the attached files) and one shall see that on e graph has 5 points(as expected) and the other has 0.
Associated revisions
support 25D layers in network analysis library (fix #11952)
support 25D layers in network analysis library (fix #11952)
(cherry picked from commit 904dc216251d183305ba1c5dc6c846be10a879db)
History
#1 Updated by Jürgen Fischer over 9 years ago
- Category set to 113
#2 Updated by Alexander Bruy over 8 years ago
- Status changed from Open to Closed
Fixed in changeset 904dc216251d183305ba1c5dc6c846be10a879db.
#3 Updated by Giovanni Manghi almost 8 years ago
- Category changed from 113 to Analysis library