sbraden / circle-craters

A planetary science crater-counting plugin for QGIS
BSD 3-Clause "New" or "Revised" License
17 stars 10 forks source link

Bug fix diameter calculation error #22

Open BerginJay opened 3 years ago

BerginJay commented 3 years ago

Bug description

The craters' diameters might go wrong when project CRS is inconsistent with layer CRS. For example the crater diameter failed to convert to meters when layer CRS is geographic coordinate system while the project CRS is a projected coordinate system.

Current state

Now circle-craters can work correctly when layer CRS / project CRS are both projected or project CRS is projected with geographic layer CRS.

Known issue

When project CRS is geographic and layer CRS is projected, one might get wrong diameter measurement. But this CRS situation should be avoid since one would need projected CRS to preform accurate measurement. And thanks to On-The-Fly Projection, we can get a projected view by only set project CRS to projected, regardless of layer CRS.

Miscellaneous

script cleanup: