enricofer / refFunctions

6 stars 10 forks source link

intersecting_geom_count uses within #11

Closed nantodevison closed 7 years ago

nantodevison commented 7 years ago

hello,

I'm using refFunctions 1.3 on Qgis 2.14 Win32. I tried to use intersecting_geom_count to update an attribute of a line with the count of buffers intersected. As shown in the following picture the preview give me 0, instead of 2 (the final results is as the preview). intersecting_geom_count_error

i looked in the code and found at line 1267 : if feat.geometry().within(feature.geometry()): Shouldn't it be if feat.geometry().intersects(feature.geometry()):

I tried and the preview gives me 1, but final result is 2 as i wanted. Is it ok for you to change the spatial test with intersects ?

Your sincerely PS : it is the first time I raise an issue so i might not be as clear as is should, forgive me if it's the case.

enricofer commented 7 years ago

Yes you thouch it. it'a a bug. fixed with https://github.com/enricofer/refFunctions/commit/9121e3c3513fdf3236f60e78f1b8fd2fb6248841 thanks for submission

nantodevison commented 7 years ago

Thanks for the correction and for the extension too : it's a great help in my work.

Have a nice day Martin

enricofer commented 5 years ago

Migration to core: https://github.com/enricofer/refFunctions/wiki/Migration-to-core