forked from anitagraser/pgRoutingLayer
-
-
Notifications
You must be signed in to change notification settings - Fork 19
Documentation v2.2
Vicky Vergara edited this page Aug 10, 2017
·
35 revisions
- pgRouting home page.
- Supported functions
All pgRouting functions from version pgr-2.0 only support integer on identifiers and float8 on costs. Functions like pgr_dijkstra only work for one source to one target. pgRouting is being rewritten gradually to support ANY-INTEGER & ANY-NUMERICAL and also to support one/many sources to one/many targets.
This 2.2 version of pgRoutingLayer works depending on the pgRouting version as follows:
- About deprecated functions:
- If the function has being deprecated on pgr-2.1, then the function will not show on pgr-versions >= 2.1
- If the function has being deprecated on pgr-2.2, then the function will not show on pgr-versions >= 2.2
- etc
- About re-factored functions with support on one/many sources to one/many targets also support ANY-INTEGER & ANY-NUMERICAL:
- If the function was re-factored on pgr-2.1, then the re-factored version is used on pgr-versions >= 2.1
- If the function was re-factored on pgr-2.2, then the re-factored version is used on pgr-versions >= 2.2
- etc
In the following table:
- an "X" means that the function is not available
- an "R" means that the function is using the re-factored version (supporting ANY-INTEGER & ANY-NUMERICAL)
- an "M" means that "many" sources/targets can be used.
- an "O" means that the function is using the original function (supporting
idandfloat)
| function | pgr 2.0 | pgr 2.1 | pgr 2.2 | pgr 2.3 | pgr 2.4 | pgr 2.5 |
|---|---|---|---|---|---|---|
| pgr_alphaShape | O | ANY | ANY | |||
| pgr_astar | O | int | int | |||
| pgr_bdastar | O | int | int | |||
| pgr_bddijkstra | O | int | int | |||
| pgr_dijkstra | O | RM | RM | RM | RM | RM |
| pgr_drivingdistance | O | RM | RM | RM | RM | RM |
| pgr_kDijkstra(Cost) | O | O | X | X | X | X |
| pgr_kDijkstra(Path) | O | O | X | X | X | X |
| pgr_ksp | O | RM | RM | RM | RM | RM |
| pgr_trsp(Node) | O | int | int | |||
| pgr_trsp(Edge) | O | int | int | |||
| pgr_trsp(via edges) | X | O | int | |||
| pgr_trsp(via vertex) | X | O | int | |||
| pgr_tsp(Euclidean distances) | X | int | int |
-
For naming:
- < U|D >:
- U = Undirected
- D = Directed
- < bbox > = xMin yMin, xMax yMax
- M = when Export Merged button is used
- < U|D >:
-
Information about the pgr-v2.2 is also included
- Uses BBOX of the QGIS canvas to limit the edges in the query
- The alpha shape is based on the results of
pgr_drivingDistance:-
pgr-v2.0: Identifiers are converted to
int4type. Costs are converted tofloat8 -
pgr-v2.1 & pgr-v2.2:
pgr_drivingDistancefor one starting vertex is used.
-
pgr-v2.0: Identifiers are converted to
- Buttons:
- Preview: Draws in the canvas the area of the alpha shape
- Clear Preview: Removes from the canvas objects generated with Preview
- Export: Creates a new layer containing the multi polygon geometry named:
(< U|D >) alphashape: <source_id> dd = <value> BBOX(< bbox >)
- Uses BBOX of the QGIS canvas to limit the edges in the query
-
pgr-v2.0, pgr-v2.1 & pgr-v2.2 & pgr-v2.3: Identifiers are converted to
int4type. Costs are converted tofloat8 - Buttons:
- Preview: Draws in the canvas the resulting path.
- Clear Preview: Removes from the canvas objects generated with Preview
- Export: Creates a one row per edge line geometry layer
- Export Merged: Creates a one row per path multiline geometry layer. Only one row is generated
- Layer name:
(< M >< U|D >) astar: < source_id > to < target_id> BBOX(< bbox >)
Example: pgr_astar from 2 to 3 on Undirected graph:
| pgRouting versions | graph | note |
|---|---|---|
| v2.0 v2.1 v2.2 | ![]() |
pgr_astar has a bug |
| v2.3 | ![]() |
pgr_astar bug is fixed |
- Uses BBOX of the QGIS canvas to limit the edges in the query
-
pgr-v2.0, pgr-v2.1 & pgr-v2.2: Identifiers are converted to
int4type. Costs are converted tofloat8 - Buttons:
- Preview: Draws in the canvas the resulting path
- Clear Preview: Removes from the canvas objects generated with Preview
- Export: Creates a one row per edge line geometry layer
- Export Merged: Creates a one row per path multiline geometry layer. Only one row is generated
- Layer name:
(< M >< U|D >) bdAstar: < source_id > to < target_id> BBOX(< bbox >)
- Uses BBOX of the QGIS canvas to limit the edges in the query
-
pgr-v2.0, pgr-v2.1 & pgr-v2.2: Identifiers are converted to
int4type. Costs are converted tofloat8 - Buttons:
- Preview: Draws in the canvas the resulting path
- Clear Preview: Removes from the canvas objects generated with Preview
- Export: Creates a one row per edge line geometry layer
- Export Merged: Creates a one row per path multiline geometry layer. Only one row is generated
- Layer name:
(< M >< U|D >) bdDijkstra: < source_id > to < target_id> BBOX(< bbox >)
- Uses BBOX of the QGIS canvas to limit the resulting path(s)
-
pgr-v2.0: Identifiers are converted to
int4type. Costs are converted tofloat8; single source & target. , pgr-v2.1 & pgr-v2.2: Multiple source & target - Buttons:
- Preview: Draws in the canvas the resulting path
- Clear Preview: Removes from the canvas objects generated with Preview
- Export: Creates a one row per edge line geometry layer
- Export Merged: Creates a one row per path multiline geometry layer. As many rows as needed.
- Layer name:
(< M >< U|D >) dijkstra: < source_ids > to < target_ids> BBOX(< bbox >)
The export button results

The export merge results

-
pgr-v2.0: Identifiers are converted to
int4type. Costs are converted tofloat8; single source , pgr-v2.1 & pgr-v2.2: Multiple source - Buttons:
- Preview: Draws in the canvas points within the driving distance
- Clear Preview: Removes from the canvas objects generated with Preview
- Export: Creates a one row per point point geometry layer
- Export Merged: Creates a one row per edge line geometry layer
- Layer name:
(< M >< U|D >) drivingDistance: < source_ids > dd = < value > BBOX(< bbox >)
- Uses BBOX of the QGIS canvas to limit the edges in the query
-
pgr-v2.0, pgr-v2.1, pgr-v2.2: Identifiers are converted to
int4type. Costs are converted tofloat8 -
pgr-v2.2: Function is being deprecated in favour of
pgr_dijkstraCostwhich is not yet implemented in this plugin. - Buttons:
- Preview: Draws in the canvas a straight line from the start_vid and a label with the cost information at the target_vid.
- Clear Preview: Removes from the canvas the objects generated with Preview
- Uses BBOX of the QGIS canvas to limit the edges in the query
-
pgr-v2.0, pgr-v2.1 & pgr-v2.2: Identifiers are converted to
int4type. Costs are converted tofloat8 - Buttons:
- Preview: Draws in the canvas the resulting path
- Clear Preview: Removes from the canvas objects generated with Preview
- Export: Creates a one row per edge line geometry layer
- Export Merged: Creates a one row per path multiline geometry layer. As many rows as needed
- Layer name:
(< M >< U|D >) kDijkstra: < source_id > to [tarjets_ids] BBOX(< bbox >)
-
pgr-v2.0: Identifiers are converted to
int4type. Costs are converted tofloat8; single source , pgr-v2.1 & pgr-v2.2: Multiple source - Buttons:
- Preview: Draws in the canvas points within the driving distance
- Clear Preview: Removes from the canvas objects generated with Preview
- Export: Creates a one row per point point geometry layer
- Export Merged: Creates a one row per path multiline geometry layer. As many rows as needed
- Layer name:
(< M >< U|D >) drivingDistance: < source_ids > K = < value > BBOX(< bbox >)
- Uses BBOX of the QGIS canvas to limit the edges in the query
-
pgr-v2.0, pgr-v2.1 & pgr-v2.2: Identifiers are converted to
int4type. Costs are converted tofloat8 - Buttons:
- Preview: Draws in the canvas the resulting path
- Clear Preview: Removes from the canvas objects generated with Preview
- Export: Creates a one row per edge line geometry layer
- Export Merged: Creates a one row per path multiline geometry layer. One row is generated.
- Layer name:
(< M >< U|D >) trsp(Node): < source_id > to < tarjets_id > BBOX(< bbox >)
- Uses BBOX of the QGIS canvas to limit the edges in the query
-
pgr-v2.0, pgr-v2.1 & pgr-v2.2: Identifiers are converted to
int4type. Costs are converted tofloat8 - Buttons:
- Preview: Draws in the canvas the resulting path
- Clear Preview: Removes from the canvas objects generated with Preview
- Export: Creates a one row per edge line geometry layer
- Export Merged: Creates a one row per path multiline geometry layer. One row is generated.
- Layer name:
(< M >< U|D >) trsp(Node): < source_id > to < tarjets_id > BBOX(< bbox >)
- Uses BBOX of the QGIS canvas to limit the edges in the query
-
pgr-v2.0, pgr-v2.1 & pgr-v2.2: Identifiers are converted to
int4type. Costs are converted tofloat8 - Buttons:
- Preview: Draws in the canvas the resulting path
- Clear Preview: Removes from the canvas objects generated with Preview
- Export: Creates a one row per edge line geometry layer.
- Export Merged: Creates a one row line geometry layer. One row is generated.
LIMITATIONS
-
Export and Export Merged:
- Does not work on points that are on the same edge.
- Uses BBOX of the QGIS canvas to limit the edges in the query
-
pgr-v2.0, pgr-v2.1 & pgr-v2.2: Identifiers are converted to
int4type. Costs are converted tofloat8 - Buttons:
- Preview: Draws in the canvas the resulting path
- Clear Preview: Removes from the canvas objects generated with Preview
- Export: Creates a one row per edge line geometry layer.
- Export Merged: Creates a one row line geometry layer. One row is generated.
- Layer name:
(< M >< U|D >) trsp(via vertex): < source_id > to < tarjets_id > BBOX(< bbox >)
- does not use BBOX
-
pgr-v2.0, pgr-v2.1 & pgr-v2.2: Identifiers are converted to
int4type. - Buttons:
- Preview: Draws in the canvas the resulting path, and a label
- Clear Preview: Removes from the canvas objects generated with Preview
Maintained by the pgRouting Community
Website: https://pgrouting.org

