x


Planet made out of terrains

Is it possible to make a planet out of 6 terrains to make a cube then with a bit of coding turn that cube into a spherical planet? I have been looking into Procedural planets but that all seems a bit complicated to me, I only want 1 planet that is always rendered, I have been attempting to make it happen with fail after fail, So im asking if it IS actually possible to do?

Thanks.

more ▼

asked May 26 '12 at 11:28 AM

British89 gravatar image

British89
36 3 5 8

like in KSP

May 26 '12 at 11:34 AM qwertyqaz

I assume you mean Kerbal space program? Yes similar to that, But im not sure they used 6 terrains though.

May 26 '12 at 11:41 AM British89

mayby you can ask them how thay did it?

May 26 '12 at 11:43 AM qwertyqaz
(comments are locked)
10|3000 characters needed characters left

3 answers: sort voted first

Unity terrains can't be rotated, so no. You have to do your own spherical terrain system.

more ▼

answered May 27 '12 at 04:16 AM

Eric5h5 gravatar image

Eric5h5
81.5k 42 133 529

(comments are locked)
10|3000 characters needed characters left

alt text

I would say that it wasn't impossible with 6 faces but there would be no way of projecting the edges at an angle - so I think it would always look odd. More faces though and it might work.

You'd need an algorithm to map a 3d point onto a face and an x,y coordinate for that face, then project the Z to the height of the terrain at that location.

So you'd need to calculate the point of intersection of the face's plane from a ray projected from the centre of the virtual sphere, then get the angle of the ray to the plane. Using trig you know that the point on the plane which needs the height is a perpendicular (it's angle will be 90), you know the angle of intersection so you can figure out the point that it touches the plane. You also know the distance from the plane - so that is the height for that point on the terrain.

Now clearly you'd want to plot a few spherical points and interpolate the heights between them. on each face. Giving extra consideration to the joins.

I guess you could also distort by a sphere as well, just adding your smoothed 3d heights to the existing height might make it look interesting.

Anyway just a thought. No idea what performance would be like :)

more ▼

answered May 26 '12 at 09:20 PM

whydoidoit gravatar image

whydoidoit
33.7k 14 24 105

On reflection heights would have to be zero at all of the edges otherwise it wouldn't work - I think that means you'd need a lot of faces before it looked right.

Procedural planets are sounding better by the second :)

How about building a procedural planet by wrapping a terrain around a sphere - now that might look good :)

May 27 '12 at 02:55 AM whydoidoit
(comments are locked)
10|3000 characters needed characters left

i made something like what you are trying to do its pretty simple acually and need no modeling skills thanks to youtube i used blender to model a sphere and used the noise button a few times then morphed the sides of the sphere to match the top there are plenty of toturials out there to follow in the end it looks like mountains and all you got to do is uv map it be sure to uv map before you subdivid or blender will freeze trying to map out with all the verticies and bumps hope this helps.

more ▼

answered Jun 18 '12 at 04:29 AM

kidrockkenny gravatar image

kidrockkenny
1 6 11 13

(comments are locked)
10|3000 characters needed characters left
Your answer
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Topics:

x1521
x355
x307
x301
x69

asked: May 26 '12 at 11:28 AM

Seen: 953 times

Last Updated: Jun 18 '12 at 04:29 AM