DZone
Big Data Zone
Thanks for visiting DZone today,
Edit Profile
  • Manage Email Subscriptions
  • How to Post to DZone
  • Article Submission Guidelines
Sign Out View Profile
  • Post an Article
  • Manage My Drafts
Over 2 million developers have joined DZone.
Log In / Join
  • Refcardz
  • Trend Reports
  • Webinars
  • Zones
  • |
    • Agile
    • AI
    • Big Data
    • Cloud
    • Database
    • DevOps
    • Integration
    • IoT
    • Java
    • Microservices
    • Open Source
    • Performance
    • Security
    • Web Dev
DZone > Big Data Zone > When Earth Is Like an Egg: 3D Terrain Visualization

When Earth Is Like an Egg: 3D Terrain Visualization

Some of the most satisfying breakthroughs happen when technology gets used in a way it was never intended. Check out how open-source software StippleGen, which was originally intended for egg painting, was applied to 3D terrain modeling.

Ken Goulding user avatar by
Ken Goulding
·
Jun. 17, 16 · Big Data Zone · Analysis
Like (2)
Save
Tweet
5.07K Views

Join the DZone community and get the full member experience.

Join For Free

some of the most satisfying breakthroughs happen when technology gets used in a way it was never intended . while working with our graphic design group at sasaki on ways to generate a dot pattern for a decorative screen, we came across some open-source software called stipplegen . stippling is a way of creating an image by means of dots. stipplegen was created to optimize stippling for, among other things, egg painting. the software does a great job of laying out dots with greater density on the darker areas of the image while keeping a comfortable spacing between the dots. what's more, the voronoi algorithm it uses gives an irregular, organic pattern. the ah-ha moment came when i realized this could be applied to a different problem, visualizing terrain; specifically, optimizing terrain meshes in 3d software based off of elevation data (a.k.a. digital elevation model (dem)).

here's a typical use of stipplegen:

image title

(image from http://www.exaptive.com/blog/when-earth-is-like-an-egg-3d-terrain-visualization-0 )


used to create this:

stippled_egg.jpg (image from http://wiki.evilmadscientist.com/stipplegen )


so, how do we get from eggs to terrain? a given terrain, unlike an egg, is typically a mix of high variation areas, like canyons, with more uniform areas, like plains or plateaus. a typical dem heightmap can be seen in the following image (top left) alongside some more familiar, human-readable representations of the same terrain that you might see on maps. shaded relief is a useful trick for representing terrain in 2d where the terrain appears to be lit from one side.

terrain_maps_shaded.jpg

( image from: https://trac.osgeo.org/ossim/attachment/wiki/ossim-chipper/dem.jpg )


while shaded relief is an effective way of representing terrain for maps (from directly above) it is insufficient for 3d representations like those you might find in cad software, virtual reality, or video games. the challenge with generating 3d mesh images from heightmaps is that the heightmaps typically contain significantly more information than you can capture in a 3d mesh without blowing up the polygon count and slowing down your frame rate to the point where smooth animation or manipulation in real-time becomes impossible even with high powered gpus. a variety of sophisticated algorithms exist for optimizing meshes, but they can be time-consuming and require specialized tools that are hard to generalize across multiple workflows.

what we realized was that we could use the open source stipplegen tool and modify it to take in both a heightmap as well as a variance map (an image using darker grays to represent those areas with the greatest variation in the heightmap). this crowded the dots in the areas of greatest variation resulting in more detail where we wanted it. we could also control the density and level of detail of the resulting mesh using a slider. what's more, the organic quality of the dot distribution also helped reduce the bias imposed by a regular grid where details could fall between the cracks.

the result is a tool that provides a highly optimized 3d mesh for use in everything from autodesk revit, 3d studio max, rhino, sketchup, unity, or webgl. all from a tool created for decorating eggs! a technological exaptation !

here's our terrain data in stipplegen using a variance map to concentrate the dots where we want them:

egg_image.png

using stipplegen's layout, we converted it to a 3d terrain map in revit:

landscape_mesh_image.png
EGG (file format) Open source Visualization (graphics)

Published at DZone with permission of Ken Goulding. See the original article here.

Opinions expressed by DZone contributors are their own.

Popular on DZone

  • Build a Serverless URL Shortener With Go
  • How API Management Can Ease Your Enterprise Cloud Migration
  • DevOps Security Checklist for Kubernetes
  • Write Your Kubernetes Infrastructure as Go Code - Extend cdk8s With Custom Constructs

Comments

Big Data Partner Resources

X

ABOUT US

  • About DZone
  • Send feedback
  • Careers
  • Sitemap

ADVERTISE

  • Advertise with DZone

CONTRIBUTE ON DZONE

  • Article Submission Guidelines
  • MVB Program
  • Become a Contributor
  • Visit the Writers' Zone

LEGAL

  • Terms of Service
  • Privacy Policy

CONTACT US

  • 600 Park Offices Drive
  • Suite 300
  • Durham, NC 27709
  • support@dzone.com
  • +1 (919) 678-0300

Let's be friends:

DZone.com is powered by 

AnswerHub logo