-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Conversation
48cedce
to
3fe3a32
Compare
1192b49
to
21e3c22
Compare
|
||
// <distance, range1, range2> | ||
using DistPair = std::tuple<double, IndexRange, IndexRange>; | ||
class Comparator { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could be free function (in a nameless namespace)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I use this customer class as the comparator of priority_queue, I tried to use lambda, but it does not work with alias-declaration.
dd9c186
to
8a655e3
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please rebase the branch, the new clang-tidy checks have landed.
9db4c43
to
7a64458
Compare
d445ea5
to
19f794a
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit + changelog
Add distance unit choices Fix cmake and add license Add support for LineString Features Add template to geometry helper function Only support line and point Rename geometry_within.cpp hpp file to geometry_util.cpp .hpp Remove incorrect indexFilter, fix pointSetsDistance Fix distance expression
…ion in geometry_util, add range assertion for distance contaniner IndexRange Change distance units to small letters, update tests accordingly
7f669f7
to
d2c08b8
Compare
Launch Checklist
This pr introduces a new expression called
distance
. It calculates the shortest distance between the geoObject input and the feature geometry. The expression will return. distance in the unit that is provided inside the expression as an argument. If theUnit
is not provided, the default unit typeMeters
will be taken into use.The format of this expression is as following:
The first version of this expression will support Geometry type :
Point
,MultiPoint
,LineString
andMultiLineString
.One example of using expression with
filter
would have following effects :@mapbox/maps-android @mapbox/maps-ios @mapbox/core-sdk
if this PR adds or updates a public API@mapbox/gl-js
if this PR includes shader changes or needs a js port @mapbox/gl-jsneeds changelog
label if a changelog is needed (remove label when added)expression-tests and render-tests: mapbox/mapbox-gl-js#9602