pioneerspacesim/pioneer — pull request #3184 by fluffyfreak (2014-09-16 19:45:20+00:00)
Title: Terrain detail / depth changes

This does the three following things:
* Calculate the maximum depth that we should go to in the quad-tree.
* Alter the spread of the detail level range from 7<>55 to 9<>129.
* Record the number of patches we're drawing per-frame.

It calculates the maximum depth by aiming to reach quads with sides approximately 50 metres in length. This sounds big but we're in spaceships and having looked at the wireframe I can assure you that you won't notice!

(7*7)*2 = 98 triangles is not a large batch of triangles! Upped slightly to 9*9*2 = 162, still not great and I may play with these ranges again in the future. However the new upper limit for maximum detail is approaching what we can handle with 16 bit indices at 33,282 triangles.
I think we can find one more higher value thanks to being constrained to a difference of only one quad tree neighbour but then we'll have to go to 32 bit indices.
Not that it really matters since even my PC crawls along drawing the ~280 million triangles that result from using the new highest detail level ;)

Some more development info so I can compare what's being generated, to what's being rendered when profiling etc.