Friday, December 16, 2016

Dealing with the Great Big World 2

My post yesterday entitled "Dealing with the Great Big World" failed to fully make clear what part of the "Great Big World" problem was being addressed. It is the storage aspect which is being addressed there.  Storing a complete high resolution elevation data set for a planet as raster data, or contours, or meshes, is possible but impractical without consuming extremely large quantities of disk space.  The combination of coarse raster data and details via vector-based definitions that can drive a procedural representation offer a better option with respect to stoarage size.

This is part of the reason for the "spline" series of posts I'm making.  Splines for defining mountain ridgelines have a great potential for a compact representation of mountain ranges.  Alternately, the splines can define the center line of a wider ranger.  Note that I'm using "splines" here as a shorthand for any open linear skeletal primitive, including not only the rounded nonuniform splines used in my "spline" examples but also line segments, polylines, etc.  They're all transformed "behind the scenes" to a sequence of one or more line segments.

Using a related technique, a polygon can be used to define the boundaries of a larger and less linear area of mountains.  This also applies to other closed primitives such as squares, circles, etc.  All of these can be converted into a closed sequence of line segments.

The other two areas of concern in dealing with the "Great Big World" are coordinate precision and the rounded shape of the world.  How those are resolved in conjunction with the solution I mentioned above is unclear.  Persisting the coordinates that define splines (and other skeletal primitives) using double precision numbers may be part of the solution, as could using the "segmented distance" approach for perssistence.  Storing coordinates as double precision latitude and longitude might work.  In all cases, conversion to an appropriate coordinate system for rendering will be required.  It is entirely possible that conversion for preprocessing will also be required.  I have more thinking to do in that regards.

No comments:

Post a Comment