-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
fill-extrusion-flat-ceilings style spec property #10355
Comments
@karimnaaji started work on scoping the mechanism.
Do you see that it would be beneficial to style it differently?
|
For the vegetation use case, I don't think that's too important. |
Some other interesting use cases for such a property: https://cameronwkruse.com/home/projects/glacslide/. Some considerations to properly support the non-flat case:
|
Another use case for non-flat ceilings of extrusions which follow the terrain is visualising land zoning restrictions of maximum building height. Source data might have large polygons covering several blocks together, so using a fixed height of extrusion would result in a wrong visualisation. |
Thanks for looking into this. My use case is to mark areas of turbulence behind hills in different wind directions. The turbulence isn't flat, nor exactly follows the ground elevation but having the ability to follow the ground elevation would be preferable. Adding some form of tilt setting would also help immensely as the turbulence tapers off by distance from the top of the hill but I appreciate that is just adding further complexity. My planned approach was to use a series of stepped polygons which would be visually inferior. |
Hello all! I am writing in this issue thread to report a behavior in GL JS v2.2 that I think is a bug unless I am missing something. This is basically what I want to achieve but with 3D terrain enabled. I don't have any issues if some of the tiles intersect or get hidden by the terrain on lower elevations. |
@searoutefinder mapbox-gl-js/src/data/bucket/fill_extrusion_bucket.js Lines 305 to 306 in e9ee222
If the feature has no In opposite case, e.g. opacity-terrain-flat, features have properties:
and roof is flat: |
Hey astojilj, First of all, let me thank you for your quick response! Thanks again! Tamas |
@searoutefinder @TheMapleSyrupCan Thank you for clarifying this. This is the same issue as with custom roof approach, when additional fill extrusion layer is used only for roof (base == height), enabling different paint for roofs, e.g.: |
I'm happy with the output we got from the thread here. Thanks. One way to address this would be by adding properties: "fill-extrusion-height-terrain-alignment" and "fill-extrusion-base-terrain-alignment", e.g.:
@karimnaaji, this would extend previous approach by supporting base, too. WDYT? |
did this every get resolved? We are hitting this issue too and would like to be able to decide whether the extrusions should be relative to the 3D terrain or flat (i.e. mean sea level). |
Hi @astojilj, With a fill-extrusion-base-terrain-alignment equal to flat, this would solve our problem for upper floor. Do you know if there is any update about it ? Thanks a lot |
Hello, Interesting topic here. We also would like to be able to decide whether the base and/or ceiling should be relative to the 3D terrain or flat (AMSL or ASFC) Thanks. |
Hello! Any news on this feature? Thank you! |
Thanks for your patience on this - we were busy with other 3D features! We'll take a look. |
Thanks for your patience, we have introduced new style spec properties to help with this issue. They landed in v3.8.0. Both properties work with the 'fill-extrusion' layer type, they can be either 'terrain' or 'flat' and control respectively the ceiling (aka 'height') and the floor (aka 'base'):
Let us know if there's any issues on these as they are experimental for now. |
Excellent news @speps ! Gonna try it out asap! Thank you. |
Motivation
When using fill-extrusions on a map with terrain enabled, since #10347 the extrusion ceiling will be flat. This is good for buildings, but per #10170 (comment) sometimes you might want these extrusions to follow the terrain.
One example is for vegetation extrusions to show forest areas of a fixed height above the terrain.
Design Alternatives
The user could split the polygons but they still would be flat, just stepped. A smoother extrusion which follows the terrain could only be achieved my unlocking it with a style spec property.
Design
Using a style spec property which defaults to flat allows backwards compatibility, but still supporting curved extrusion ceilings.
It's fine if this is not something you're keen on implementing, but thought I'd raise this ticket for further discussion since the existing ones were closed out.
The text was updated successfully, but these errors were encountered: