1
Builds & Ports / Re: Android Port
« on: September 23, 2011, 01:00:29 am »The ocean, however, isn't. Technically it doesn't really exist, there are no pre-existing polygons or anything, the land is just placed on top of a blue circle. So to shade it like a sphere, which is a lot smoother than the land, a lot of complex expensive stuff goes on, I'm not really sure what since I didn't code it. But I presume the game basically has to generate polygons for the ocean, figure out their positions up to the circle edge, convert them, shade them, draw them, all this every game tick. It's constantly caching so it can't be cached or whatever either. It's basically a really ugly mess and nobody's figured out a fast way of doing it yet.
What if you created a fine grid of longitude strips and cached those every time you move the globe. Then every game tick you would have to find out which longitudinal strips changed shade and redraw them, nothing else. The problem I see with this method is finding where the edge of the globe is so you aren't drawing the back side of the earth.
This would definitely not help me with making globe motion smoother in my UI, but it might make the draw ever so slightly less. I'll still work on making those ugly equations simpler or at least less time consuming. Is ther biggest problem with the globe the water shading? (the "tame the beast" comment you made earlier)