Closed cm8 closed 6 years ago
Thanks for contribution. It is quite a lot changes, I need some time to review them all. I'm curious about changes in render, they looks ok but I would like to test it first. I try do it on this weekend.
No problem, take your time. Please share your thoughts on potential mistakes or bottlenecks, by discussing them we might both gain some knowledge.
I'm currently hacking at Road.java - until now, if a highway uses area=yes, the road is rendered on the outline. I've split model building to actually build an area model (like in Water.java) when area=yes is present. It basically works, but choosing right texture is not done yet (since the area is triangulated it needs separate, unoriented texture)..
Still didn't have time to test it. Please be patient, I will do it in next week.
Looks like front back materials are working fine now. Thank you for your contribution. Its first so big patch. Sorry that it took me so long to review it. I promise be quicker next time.
Oki I have added formatter which I use in commit 03bfb515069c7fad4c81d95c14f81bcddb5c3cc7 Application with yours changes has been released as version 1.0.200 :)
Don't be sorry for long review time. My pull request was not perfect at the beginning. You've noticed a couple of glitches that were worth fixing before the merge. I rather have someone taking time and re-think / test the changes made, than a "blind" merge. To spot mistakes, four eyes are better than two.
It would have been OK with me, if you took another week or two for your review.
Drivers on our machines are not too different, it seems (or workarounds to driver glitches are implemented on a lower level, in jogl e.g.). It would help, if we had someone using NVIDIA graphics card / drivers. I can only test on radeon and intel hardware and assume you're using radeon as well.
I suspect alpha blending and face culling may have worked for you before, but did not so here. Might be driver or jogl implementation issue? Or if it did not work for you before (black opaque rendering of fence faces instead of transparent areas), it does so now.
Integrated checking for an active filter in JOSM was added, so now in 3D View you will see the same objects as in 2D View. If objects are disabled and hidden from the 2D View, then they are likewise in 3D view. This works nicely to reduce the load on the 3d renderer or if you just want to visualize a certain aspect of the data (like buildings only, streets only, waterways only, etc..)
To sync an active filter you currently have to close 3d window, delete camera layer, open 3d window, because JOSM does not properly generate DataChangedEvent when a filter is applied or removed (no event is triggered at all, I've sent a patch to fix this, see ticket 15670 on josm trac). If ticket 15670 is applied to josm core, this works out of the box, without closing the 3d window. At least I have it working here.
A last major thing of this pull request is fixing multipolygon assembly for poly2tri input. A lot of waterway riverbanks e.g. were not displayed correctly, because they use multiple outer parts to form an outer ring. In PolygonWithHolesUtil.java there were checks to not include a duplicate node of a closed way, but if a list of multiple outer ways are assembled, there is a dup node condition just as well (each end node of a way in the input list is also start node of the next way), so we actually have to skip one node for all outer way parts. If you leave the dup nodes in place the delaunay triangulation won't work.
On the UI side an option was added to switch off textures (show all objects in mono ambient color).