[jira] [Commented] (LUCENE-7951) New wrapper classes for Geo3d

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[jira] [Commented] (LUCENE-7951) New wrapper classes for Geo3d

JIRA jira@apache.org

    [ https://issues.apache.org/jira/browse/LUCENE-7951?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16164318#comment-16164318 ]

ASF GitHub Bot commented on LUCENE-7951:
----------------------------------------

Github user iverase commented on a diff in the pull request:

    https://github.com/apache/lucene-solr/pull/246#discussion_r138556038
 
    --- Diff: lucene/spatial-extras/src/java/org/apache/lucene/spatial/spatial4j/Geo3dDistanceCalculator.java ---
    @@ -70,7 +71,22 @@ public boolean within(Point from, double toX, double toY, double distance) {
     
       @Override
       public Point pointOnBearing(Point from, double distDEG, double bearingDEG, SpatialContext ctx, Point reuse) {
    -    throw new UnsupportedOperationException();
    +    double dist = DistanceUtils.DEGREES_TO_RADIANS * distDEG;
    +    double bearing = DistanceUtils.DEGREES_TO_RADIANS * bearingDEG;
    +    Geo3dPointShape geoFrom = (Geo3dPointShape) from;
    +    GeoPoint point = (GeoPoint)geoFrom.shape;
    +
    --- End diff --
   
    I have changes the formula to use vincenty's formulae. Slower as it is iterative but It taken into account the planet model.


> New wrapper classes for Geo3d
> -----------------------------
>
>                 Key: LUCENE-7951
>                 URL: https://issues.apache.org/jira/browse/LUCENE-7951
>             Project: Lucene - Core
>          Issue Type: Improvement
>          Components: modules/spatial-extras
>            Reporter: Ignacio Vera
>            Assignee: David Smiley
>            Priority: Minor
>         Attachments: LUCENE_7951_build.patch, LUCENE_7951_build.patch, LUCENE-7951.patch, LUCENE-7951.patch
>
>
> Hi,
> After the latest developments in the Geo3d library, in particular:
> [https://issues.apache.org/jira/browse/LUCENE-7906] : Spatial relationships between GeoShapes
> [https://issues.apache.org/jira/browse/LUCENE-7936]: Serialization of GeoShapes.
> I propose a new set of wrapper classes which can be for example linked to Solr as they implement their own SpatialContextFactory. It provides the capability of indexing shapes with
>  spherical geometry.
> Thanks!



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]