Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bounding Box support? #58

Open
cody-elhard opened this issue Sep 1, 2022 · 2 comments
Open

Bounding Box support? #58

cody-elhard opened this issue Sep 1, 2022 · 2 comments

Comments

@cody-elhard
Copy link

cody-elhard commented Sep 1, 2022

When I try to encode the following well known text, I get a nil response.

RGeo::GeoJSON.encode("BBOX(-100 30,-120 30)")

Should I just convert this to a polygon or should bounding boxes be supported?

@BuonOmo
Copy link
Member

BuonOmo commented Sep 14, 2022

Yeah RGeo::GeoJSON.encode only takes features. You could have some kind of helper to pass through anything, like https://github.com/ekylibre/charta. Although I think it is now unmaintained, you can definitely take inspiration on the new_feature method to create a convenient helper in your project (https://github.com/ekylibre/charta/blob/master/lib/charta.rb#L29)

About your mention of bounding boxes, I guess you refer to https://www.rfc-editor.org/rfc/rfc7946#section-5. There is not plan yet to support that, I don't really know how the interface could do that clearly, and I think I'd rather stick to something simple. Although if you have some design proposition in mind, please share it!

@BuonOmo
Copy link
Member

BuonOmo commented Jan 27, 2024

If anyone is up to convincing that we should do the feature, why not. In the meantime I won't have any time to dedicate to this feature unfortunately

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants