pgr_alphaShape with alpha <> 0 in v2.1.0
Dear all,
running
SELECT * FROM pgr_alphaShape('SELECT id::integer, ST_X(the_geom)::float AS x, ST_Y(the_geom)::float AS y FROM edge_table_vertices_pgr',0.1::float);
with a float > 0 always returns NULL as geometry on my machine. Running it with alpha = 0 or alpha = unset returns a valid polygon.
I run the following configuration:
- pgrouting 2.1.0 compiled with -- libcgal 4.2.5 and boost 1.54 -- tested as well with self-compiled CGAL 4.7 + boost 1.55
- POSTGIS 2.2.1
- Postresql 9.5 on Ubuntu 14.04 with PG sources from Postgresql.org repo
is this a bug in v2.1.0 and should I upgrade?
Interesting error, bug, we need to replicate can you post a link where we can get the exact same data you are using?.
Hi Vicky,
I attach the following shape file. Please rename the extension from TXT to SHP. Looking forward to your opinion. exportRenameToSHP.txt
A
A .shp by itself is not useful. Please zip up the .shp, .shx and .dbf files and send the zip file to us. Or alternatively pg_dump -U postgres -h localhost -t <table> -Fp -Z -f file.sql.gz <dbname> and send us the file.sql.gz
export.zip here you go...
Sorry for late reply. I will check above at this weekend.
Great. Thank you!
@ani82
Sorry for my late confirmation.
I confirmed that alpha value 0.1 returns nothing as you mentioned,
but large alpha value (like 1000000) returns some coordinates.
Your geometry data unit is not "decimal degree", but "meters",
so, I think that more larger value was necessary.
About alpha value meaning, please see the following site. http://doc.cgal.org/latest/Alpha_shapes_2/group__PkgAlphaShape2.html Thanks,
There is now https://postgis.net/docs/manual-dev/ST_AlphaShape.html