Currently what we first wanted to have with Dan is the calculation of an oriented bounding box. We decided to have a general 3d OOBB calculation. After checking several papers I decided to implement this solution: http://gamma.cs.unc.edu/users/gottschalk/main.pdf
If the implementation passes, I will create a pull request to the AGI fork.
While planning this project we had some discussions with Patrick and Dan about handling the label overlapping. The next step will be creating a solution for this.
Dan gave me great comments in the pull request of the ObjectOrientedBoundingBox. After fixing the issues, I continued working on a function which computes the OOBB from a BoundingRectangle and a rotation (2D solution for labelling). Also I started implementing the separating axis theorem for rectangles and boxes, so we can determine intersection of two rectangles or boxes.
Hopefully I can add these features to the pull request on the first part of next week.
I will post regularly status updates. If you have any questions about this project, do not hesitate.
I added more testcases, fixed some conflicts, and did some refactor. If you have time to tell me your opinion about this pull request, please do it. Thanks!
After Dan reviewed the code I updated the pull request. I created a function for getting the vertices from the OOBB’s properties, but Dan told me that there is already a solution for that, so I will rewrite some testcases.
During the weekend I want to compute OOBB-s for labels.
I’ve added computing the OOBB-s for labels. This will be soon a new pull request. In the next 1-2 days I’ll add the intersect checking for the Labels, + tests for that.
Dan after some fixes merged the ObjectOrientedBoundingBox model. I’ve added oobb-s to the Labels, and added computing when reposition occurs. Currently we are discussing about the declutter algorithm with Patrick and Dan. Soon I will post the fix plan and the schedule.
Dan merged the ObjectOrientedBoundingBox to the AGI/master branch. Also we had a discussion about the declutter algorithm. We decided to implement first the solution based on circle/spiral.
If we the actual label we want to place would collide we try to find a place on a circle around the original placement position. If we don’t succeed we enlarge this circle. If we still cannot find a good placement, we start playing with the translucency.
One important thing is that Label can have a priority, so the labels with a higher priority will be placed first.
During the weekend I implemented this algorithm. I need 1-2 days to complete it.
Currently I am working on setting the new position of the Label to the VBO. When I finish this, I think we can start to test the declutter based on the circle/spiral method.
Dan checked the initial declutter and gave me his czml test set. I’ve optimized the declutter after his comments. I will push the update during the weekend.
No. Unfortunately I couldn’t find time in the last couple of months to finish declutter, however I would like to continue in some way. The calculation of Object oriented bounding boxes was implemented and a half ready spiral/circle solution. The next step would be testing it. Future plan was to use force vectors.
Hi Ogi, basically when there is clutter then I was hoping for a similair result to the STk software where the labels are then spread out with a little line connecting each to its object or point of reference. AS one zooms in & the clutter is reduced the label then comes nearer.
Many thanks for your reply…
please let me know when you make further progress.
Is there any word on when this is going to continue to get worked? I see that it's part of the roadmap, but not any releases. For my project, we have some dynamic data that often results in labels being stacked right on top of each other! I have tried manually adding the changes to b27 (what we're using currently), but I think I missed some of them since I keep getting rendering issues in the updateFrustrum function.
In the meantime are there any good workarounds? I currently have a O(n^2) function that checks all labels for overlap and repositions them that runs every 1/10th of a second. I would like to try to find a more elegant solution that works more efficiently.