# The Eden Project

**URL:** <https://forums.unrealengine.com/t/the-eden-project/42321>\
**Category:** Game Development\
**Tags:** unreal-engine, Work-in-Progress\
**Created:** [September 20, 2015, 9:02am UTC](https://forums.unrealengine.com/t/the-eden-project/42321 "2015-09-20T09:02:24Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![ioFlow\_Studios](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/ioflow_studios/32/1194555_2.png) [@ioFlow\_Studios](https://forums.unrealengine.com/u/ioFlow_Studios)\
**Post date:** [September 20, 2015, 9:02am UTC](https://forums.unrealengine.com/t/the-eden-project/42321/1 "2015-09-20T09:02:24Z")

</div>

Latest WIP shot:

 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/6/7/5/6752f90df27b3551d1a1a9a2c030b87f690dcf8d.jpeg)

Original Post:

I’ve been playing around with some ideas I’ve had (for a very long time) about generating planet sized terrains for an open universe sci fi game.

I’ve managed to get a couple of very basic things going, so I thought I’d start a thread here and show everyone what I’ve got and see what you think.

Here’s a screenshot of my random planet generation code in action (previewed as simple textures at the moment):

 ![20150920_181013_post.jpg](https://d3kjluh73b9h9o.cloudfront.net/original/3X/d/7/d7a94d9f8c675c1d6da89501af09643144cd6e80.jpeg)

The first two examples above are the same settings, just with different random seeds. The third example is different settings to show how the random variations don’t have to all have the same style.

I’m using a library called Voro++ to generate a (3D) voronoi sphere as a base, simplex noise in a bunch of combinations to let me generate a nice variety of patterns, and Cairo to rasterize the end result (this let’s me zoom in indefinitely on the pattern). I’ve been taking inspiration from the work of other people online such as [this person](http://whenitsdone.org/tag/voronoi/) ] and [this person](http://experilous.com/1/blog/post/procedural-planet-generation) ]. As you can see from their examples, there are lots of cool ways to add all sorts of interesting details to worlds when you use voronoi spheres, such as mapping out a range of different biomes, river networks and even weather.

For ground level details, I’ve been learning how to use the procedural mesh components in UE4, here is a screenshot of a custom terrain mesh using some random noise to set it’s elevation:

 ![20150920_183412_post.jpg](https://d3kjluh73b9h9o.cloudfront.net/original/3X/e/5/e5cd82572329efbe49e5dba7344111a7d39b2efd.jpeg)

At the moment it’s just one octave of simplex noise - hence the very basic pattern - but the same techniques that I’m using to make the planet level patterns more interesting are just as effective at this level too.

At the end of the day I’d like ideally to be able to do something like [this](http://libnoise.sourceforge.net/examples/complexplanet/index.html) ] only in realtime inside UE4.

Obviously though there are an ocean of challenges to swim across when trying to do something like this, so I’m just going to keep poking away and try and add a little bit extra each week and see where it ends up 🙂

---

<div class="post-metadata">

**Author:** ![ioFlow\_Studios](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/ioflow_studios/32/1194555_2.png) [@ioFlow\_Studios](https://forums.unrealengine.com/u/ioFlow_Studios)\
**Post date:** [November 3, 2015, 2:17pm UTC](https://forums.unrealengine.com/t/the-eden-project/42321/2 "2015-11-03T14:17:31Z")

</div>

Managed (after much blood, sweat and tears) to swap out the Cairo Graphics library for a much faster one called Anti-Grain Geometry.

Now everything runs fast enough that I can preview the effect of all the different settings in realtime:

[![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/f/d/f/fdf27c5a332212a52fad77c02bd256c546e4600c.jpeg "eden test 151103 234400") ](https://www.youtube.com/watch?v=oHD6Mm1P4yU)

For this test I’m just doing a very basic earth like planet, but of course I’d like to be able to do all sorts of planetary bodies, from ones like this to moons, to gaseous planets to suns etc etc.

The idea is to use the settings to dial up a bunch of different designs, then to be able to scatter an infinite number of random variations of those designs around a virtual galaxy.

---

<div class="post-metadata">

**Author:** ![ProlixLegend](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ProlixLegend](https://forums.unrealengine.com/u/ProlixLegend)\
**Post date:** [November 3, 2015, 9:01pm UTC](https://forums.unrealengine.com/t/the-eden-project/42321/3 "2015-11-03T21:01:53Z")

</div>

This looks awesome! Can’t wait to see more.

---

<div class="post-metadata">

**Author:** ![ioFlow\_Studios](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/ioflow_studios/32/1194555_2.png) [@ioFlow\_Studios](https://forums.unrealengine.com/u/ioFlow_Studios)\
**Post date:** [November 9, 2015, 2:23pm UTC](https://forums.unrealengine.com/t/the-eden-project/42321/4 "2015-11-09T14:23:04Z")

</div>

Small update - implemented “Lloyds algorithm” to smooth the spacing and size of the voronoi cells:

[![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/4/5/c/45c04ddd35059300f9f7a08ee2b26bd201a94d62.jpeg "eden test 151109 232400") ](https://www.youtube.com/watch?v=Ec7UWruGQcI)

The voronoi style is quite cool, but I am going for a more realistic look so the next step is to tessellate all the edges with a mid point displacement algorithm. Once I’ve got that going I’ll migrate my old spherical LOD code into UE4 and start projecting these textures onto that instead of the boring plane above.

---

<div class="post-metadata">

**Author:** ![starseeker](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@starseeker](https://forums.unrealengine.com/u/starseeker)\
**Post date:** [November 9, 2015, 5:42pm UTC](https://forums.unrealengine.com/t/the-eden-project/42321/5 "2015-11-09T17:42:59Z")

</div>

Keep it up!

---

<div class="post-metadata">

**Author:** ![ioFlow\_Studios](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/ioflow_studios/32/1194555_2.png) [@ioFlow\_Studios](https://forums.unrealengine.com/u/ioFlow_Studios)\
**Post date:** [December 15, 2015, 2:01pm UTC](https://forums.unrealengine.com/t/the-eden-project/42321/6 "2015-12-15T14:01:24Z")

</div>

Finally managed to get the next bit going (took ages):

 ![20151215_234900_mpdsWorking.jpg](https://d3kjluh73b9h9o.cloudfront.net/original/3X/1/8/18337d04155658f0baf80d7c2b688b58961db8b9.jpeg)

So I can now subdivide and displace the voronoi cell edges to get that fractal coastline look.

More importantly, I can specify a focal point and a falloff range and as edges get further away from it they subdivide less.

That means I can pile on the detail near the player without having to worry about that being replicated across the entire planet surface and basically instantiating a black hole in UE4s memory usage.

---

<div class="post-metadata">

**Author:** ![Nemodain](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Nemodain](https://forums.unrealengine.com/u/Nemodain)\
**Post date:** [December 27, 2015, 2:37am UTC](https://forums.unrealengine.com/t/the-eden-project/42321/7 "2015-12-27T02:37:58Z")

</div>

Wow! This is awesome, keep up the work! I would love to see the out come of this.

---

<div class="post-metadata">

**Author:** ![ioFlow\_Studios](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/ioflow_studios/32/1194555_2.png) [@ioFlow\_Studios](https://forums.unrealengine.com/u/ioFlow_Studios)\
**Post date:** [January 30, 2016, 11:18am UTC](https://forums.unrealengine.com/t/the-eden-project/42321/8 "2016-01-30T11:18:41Z")

</div>

So had a hard drive die on my first day back at work at the start of January, lost all of the fractal stuff above 😕

Took me the whole month to redo it…

 ![20160130_211400.jpg](https://d3kjluh73b9h9o.cloudfront.net/original/3X/c/c/cc1e6f01fdf61e87f42da0d27b62f137b155dbd8.jpeg)

Yay computers.

(All backed up with perforce now).

---

<div class="post-metadata">

**Author:** ![ioFlow\_Studios](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/ioflow_studios/32/1194555_2.png) [@ioFlow\_Studios](https://forums.unrealengine.com/u/ioFlow_Studios)\
**Post date:** [March 15, 2016, 1:46pm UTC](https://forums.unrealengine.com/t/the-eden-project/42321/9 "2016-03-15T13:46:39Z")

</div>

FINALLY got base mesh going… screenshots soon…

---

<div class="post-metadata">

**Author:** ![ioFlow\_Studios](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/ioflow_studios/32/1194555_2.png) [@ioFlow\_Studios](https://forums.unrealengine.com/u/ioFlow_Studios)\
**Post date:** [March 22, 2016, 12:20pm UTC](https://forums.unrealengine.com/t/the-eden-project/42321/10 "2016-03-22T12:20:16Z")

</div>

Sort of a fwiw screenie:

![2d167a4aa14de6cd10db3ac232fd358e6b15f53d.jpeg](https://d1ap1mz92jnks1.cloudfront.net/images/transparent.png)

Obviously will be a bit more interesting when I get the dynamic sub division going…

---

<div class="post-metadata">

**Author:** ![Zarkopafilis](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Zarkopafilis](https://forums.unrealengine.com/u/Zarkopafilis)\
**Post date:** [March 28, 2016, 8:43am UTC](https://forums.unrealengine.com/t/the-eden-project/42321/11 "2016-03-28T08:43:04Z")

</div>

I’d buy it if it was complete and in the marketplace.

---

<div class="post-metadata">

**Author:** ![ioFlow\_Studios](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/ioflow_studios/32/1194555_2.png) [@ioFlow\_Studios](https://forums.unrealengine.com/u/ioFlow_Studios)\
**Post date:** [March 28, 2016, 11:39am UTC](https://forums.unrealengine.com/t/the-eden-project/42321/12 "2016-03-28T11:39:02Z")

</div>

What a great long weekend 🙂 Got heaps of coding done!

First of all I realised (belatedly) that everytime I used an FVector it was “floatifying” my beautiful doubles, so I spent a whole day fixing that.

Then I modified the topology of the mesh to reduce the pinching at the quadratic poles in the mesh.

Then today I got the octaves working:

 ![20160328_212700.JPG](https://d3kjluh73b9h9o.cloudfront.net/original/3X/7/2/72cdce85f36c4e9b754904cafe55c7a80907fc63.jpeg)

I almost got them repositioning around a designated point but it got all stroppy and my brain doesn’t do the clever after 10pm anymore so will have to keep hammering away this week.

---

<div class="post-metadata">

**Author:** ![Mr\_SquarePeg](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Mr\_SquarePeg](https://forums.unrealengine.com/u/Mr_SquarePeg)\
**Post date:** [March 28, 2016, 10:09pm UTC](https://forums.unrealengine.com/t/the-eden-project/42321/13 "2016-03-28T22:09:15Z")

</div>

This looks really awesome!

Cannot wait to See it finished with full scale procedural planets. 😃

- HeadClot

---

<div class="post-metadata">

**Author:** ![ioFlow\_Studios](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/ioflow_studios/32/1194555_2.png) [@ioFlow\_Studios](https://forums.unrealengine.com/u/ioFlow_Studios)\
**Post date:** [March 31, 2016, 3:39am UTC](https://forums.unrealengine.com/t/the-eden-project/42321/14 "2016-03-31T03:39:34Z")

</div>

Edging… closer… to… working… lod…

![90a332e75bda82cec80b71b27e8acfd429597f59.jpeg](https://d1ap1mz92jnks1.cloudfront.net/images/transparent.png)

Sorry 🙂

It’s just so nice to see the base terrain nearly working… another couple of nights and I should be able to move the LOD focal point around at will.

Once that’s going I can start adding in all sorts of different procedural height maps and mix between them with the dynamic texture above.

---

<div class="post-metadata">

**Author:** ![ioFlow\_Studios](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/ioflow_studios/32/1194555_2.png) [@ioFlow\_Studios](https://forums.unrealengine.com/u/ioFlow_Studios)\
**Post date:** [April 3, 2016, 1:37am UTC](https://forums.unrealengine.com/t/the-eden-project/42321/16 "2016-04-03T01:37:40Z")

</div>

Alrighty then, _finally_ get to show a working demo of my spherical terrain code in UE4 🙂

[![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/4/0/f/40fb302d6ed18f9285c16855e770b2c6c9e95831.jpeg "Eden work in progress") ](https://www.youtube.com/watch?v=3ymmsEQ6DTs)

Still need to fix a few glitches that happen if I move the focal point too quickly, and I need to find a way to make the whole thing go faster…

But still, I’m pretty happy with the progress (even though it’s taken AGES to get this far).

---

<div class="post-metadata">

**Author:** ![ioFlow\_Studios](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/ioflow_studios/32/1194555_2.png) [@ioFlow\_Studios](https://forums.unrealengine.com/u/ioFlow_Studios)\
**Post date:** [April 3, 2016, 3:25am UTC](https://forums.unrealengine.com/t/the-eden-project/42321/17 "2016-04-03T03:25:37Z")

</div>

And here it is in game:

[![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/8/d/f/8df3f6274cb9539ba202200ae28c8fb25b80804c.jpeg "Eden work in progress 160403 121528") ](https://www.youtube.com/watch?v=GBAtUTBlsH0)

And for the record, I’m working on a five year old laptop so don’t be too freaked out by the framerate 🙂

---

<div class="post-metadata">

**Author:** ![tupikp](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@tupikp](https://forums.unrealengine.com/u/tupikp)\
**Post date:** [April 3, 2016, 3:48am UTC](https://forums.unrealengine.com/t/the-eden-project/42321/18 "2016-04-03T03:48:42Z")

</div>

Is your code working in UE 4.11 as well?

---

<div class="post-metadata">

**Author:** ![ioFlow\_Studios](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/ioflow_studios/32/1194555_2.png) [@ioFlow\_Studios](https://forums.unrealengine.com/u/ioFlow_Studios)\
**Post date:** [April 3, 2016, 8:38am UTC](https://forums.unrealengine.com/t/the-eden-project/42321/19 "2016-04-03T08:38:14Z")

</div>

It certainly is 🙂

---

<div class="post-metadata">

**Author:** ![ioFlow\_Studios](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/ioflow_studios/32/1194555_2.png) [@ioFlow\_Studios](https://forums.unrealengine.com/u/ioFlow_Studios)\
**Post date:** [April 5, 2016, 11:51pm UTC](https://forums.unrealengine.com/t/the-eden-project/42321/20 "2016-04-05T23:51:26Z")

</div>

Fixed up a glitch that was ripping holes in the mesh if I moved the focal point too quickly (in the editor) which was driving me nuts.

Thought I’d see what the mesh look like 10,000 times larger with the subdivision levels cranked up from 3 to 8, no discernible impact on the frame rate 🙂

[![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/b/2/2b27bf9119053b6771e6b5a39b1a49c37fa3a0da.jpeg "Eden work in progress 160405") ](https://www.youtube.com/watch?v=9gniFP6K3Y4)

This is just me flying around manually in the editor, in game the lod focal point will follow the camera around and drop detail as your altitude gets higher.

Also, all the mesh generation settings are adjustable so I’ll probably increase the density of all the patches (they’re currently only 8 x 8 edges and each lod is made up of 4 x 4 patches).

The real performance challenge is approaching quickly - dynamic texture generation - each of those levels of detail will be getting their own texture.

---

<div class="post-metadata">

**Author:** ![ioFlow\_Studios](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/ioflow_studios/32/1194555_2.png) [@ioFlow\_Studios](https://forums.unrealengine.com/u/ioFlow_Studios)\
**Post date:** [April 6, 2016, 3:58am UTC](https://forums.unrealengine.com/t/the-eden-project/42321/21 "2016-04-06T03:58:27Z")

</div>

Now that I’ve got the mesh sort of behaving it’s very easy to throw in some basic simplex noise to see what it looks like with some height variation on it:

[![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/a/c/e/ace37e16f103ad5d171101815905a78a61d13493.jpeg "Eden wip 160406 125800") ](https://www.youtube.com/watch?v=xu-ADbn5mvE)

[Next page](https://forums.unrealengine.com/t/the-eden-project/42321.md?page=2)
