How can I render Clouds.

Started by Leerling177171, April 08, 2013, 04:18:06 AM

Previous topic - Next topic

Leerling177171

I want to render clouds in terragen 2 into a normal picture to use them as 2D clouds in a game engine could somebody explain me how?

Thank you,

Tangled-Universe

You can't export clouds into a 2D image with alpha plane with TG2.
(the alpha has a chroma component in it, which makes it useless for masking purposes. Also, ideally you don't want to use alpha mapped clouds in your game engines, as you need to trace each which slows down the game).

You can render your clouds as a skybox and use that in your game engine.
I believe one of your last questions was about a a skybox, so you should be able to get started from there.

Leerling177171

What would you prefer to get animated clouds in a gameengine ?

Matt

#3
How you want to set up your camera for rendering will depend exactly how you want to use the clouds, but I don't know if you were asking about that.

If you disable the atmosphere you can render your clouds on a black background. The alpha channel can be saved from the render view (press 'A' in the Render View to view the alpha channel, then you can save that as a separate image). T-U said the alpha channel can have a chromatic component to it. This means that the alpha isn't always a simple greyscale image in Terragen, because the atmosphere is a bit more complex than that, but for clouds the alpha will be a simple greyscale so there is no problem there. After saving your alpha image, you can convert it to a single alpha channel in Photoshop etc.

Note that if you render clouds this way, they will be premultiplied images (because the RGB fades to black wherever the alpha fades to 0), so you should take care that your game engine knows this. Otherwise you might need to unpremultiply them before using them as textures.

Later, if you want to render a sequence of frames with animated clouds, you can tell Terragen where to save the alpha channel with the "extra output images" filename.

Matt
Just because milk is white doesn't mean that clouds are made of milk.

Tangled-Universe

Ah of course Matt, thanks for clearing that up.