Open lilleyse opened 5 years ago
This also applies to ground primitives on 3D Tiles but might actually be the desired look:
The use case here is being able to draw lines on vertical surfaces. I just got this request over email. It works fine on top of the building:
But if you want to draw a line that goes over the 2nd floor windows it colors the entire vertical surface:
@OmarShehata are you trying to use a GroundPrimitive
? You would need to use a non-clamped polyline to draw on a vertical surface.
Thanks @hpinkos . You're right, I was setting clampToGround: true
there. This should be sufficient for this use case, you'd just have to be careful not to draw the line exactly on the surface so it doesn't clip through it, or perhaps use a depthFailMaterial. So what isn't supported is specifically clamping lines to vertical surfaces.
@hpinkos I came across this issue rendering OSM building footprints along with the OSM Buildings 3D tile layer. Our footprints are rendered as clamped polylines, and it appears clamped lines that parallel the edge of a 3D tile influence how the surface of the 3D tile is rendered.
In this demo, I have added a clamped polyline that outlines a building from the OSM Buildings 3D tile layer. The end result is a red building, but I would expect a red outline around the base of the building.
Is this expected behavior?
@schmidtk this does appear to be the same bug. Easiest workaround would be to set clampToGround: false
and sample the terrain height at each point along the polyline to place the outline on the ground "manually" that way. Feel free to post on the community forum (https://community.cesium.com/) if you're having trouble with this so we can move the discussion about workarounds to this specific use case there.
What should I do if I encounter a rock protruding horizontally when drawing a polyline on 3dtiles, here I set clampToGround to true
In fact, I just want to cross the line formed by these green balls and stick to the rock
Hello, is there any follow-up to this question? Is there any way to fix this
Hi @Lafeu-p, there hasn't been any activity on this item recently. Likely we would need to change our overall approach to draping polylines.
If you'd like to add more information about your use case, that may help us prioritize. If you are interesting in contributing, please let us know and we'd be happy to discuss implementation or review a PR. Thanks!
When clamping a polyline to 3D Tiles it slices through the mesh rather than draping over the topmost surface. This is a limitation of the way ground polylines are rendered.