-
Notifications
You must be signed in to change notification settings - Fork 955
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
Buffer - Observation #849
Comments
Thanks for sharing 👍 Those outcomes are expected, the smoothing edges is for normal for positive buffers. There has been some discussions (#639) about having different joining strategies (miter & flat). Those screen shots look good! Good use of high resolution imagery + TurfJS. |
As just an alternative, if useful, I'd suggest the use of var scaledPoly = turf.transformScale(poly, factor); |
Oh nice! |
Hey @stebogit A thought on this, is there any way that we could get |
👍 @rowanwins we should be able to calculate the factor internally based on a |
@rowanwins I think we need to define how to apply a distance as Example: const scaled = turf.transformScale(polygon, 10, null, false, 'miles');
I'm not sure if the result is what you would expect, however we can definitely add this feature. We can add an optional Any other idea? |
Hmm yeah maybe it's not such a smart idea, might be wisest to keep that functionality in the buffer module.... |
@stebogit Can't we just expand the |
That's alright I think I've got it sorted @DenisCarriere & @stebogit . I have a fully functional polygon buffer module with 0 dependencies (other than turf deps). I'm just adding the linestring buffer before I put in an initial pull request for your review (perhaps tonight...). Currently 5 times faster than |
@rowanwins 👍 Awesome! 🎉 Looking forward to it |
@DenisCarriere the Great @rowanwins! |
Agreed, but couldn't we also add |
Sorry didn't mean to close this... 😅 @DenisCarriere I remember we defined However, here the issue is not really the I'd actually agree with @rowanwins here, that maybe it's not the best way of think about |
Ooh yea! that's true... The user can just pass his own point 👍 Gotcha |
👍 Yes this issue topic seems more of a |
This is not an issue per se, but an observation and I'm raising on behalf of a customer as I do not have an adequate enough understanding of how this module works.
There are screen captures of two scenarios below. The first shows a buffer (in orange) set at +25m and the second shows a buffer set at -25m. The first smooths out the buffer polygon (and I can just about understand why) whilst the second makes the buffer much the same shape as the object polygon. Is this in line with what everyone expects to happen?
+25 metre buffer:
-25 metre buffer:
It does beg the question that if I set the object polygon to be the same size as the second buffer and then apply a +25 metre buffer then what would I expect to see? A buffer with the same proportions or one that is smoothed out?
To be honest, I find both results to be acceptable from an operational point of view but I still think it's worth raising the point.
But otherwise, thank you very much for such a useful utility.
Cheers.
The text was updated successfully, but these errors were encountered: