Sky Feature

Started by PeanutMocha, April 24, 2011, 01:53:54 AM

Previous topic - Next topic

PeanutMocha

I have a procedural starfield in my scene from

http://forums.planetside.co.uk/index.php?topic=4391.msg46100

Now I want to place an additional feature in the sky for which I have an image.  My thought was to add a plane, rotate it appropriately, make it big and far from the planet.  Unfortunately I can't figure out how to light my plane independently from the rest of the scene.

Am I taking the best approach?  Can I get the desired lighting this way? 


choronr

Perhaps using a light source ...not sure.

Dune

Just a thought; you could try self illuminating the image, by calling the image in the default shader's luminosity, and setting the luminosity at some high number (experiment). Just a thought thought, I never tried this. You'd also have to call the image (black edges I suppose, or alpha layer included?) in the opacity tab, to keep the outside black.

PeanutMocha

Quote from: Dune on April 24, 2011, 02:24:35 AM
Just a thought; you could try self illuminating the image, by calling the image in the default shader's luminosity, and setting the luminosity at some high number (experiment). Just a thought thought, I never tried this. You'd also have to call the image (black edges I suppose, or alpha layer included?) in the opacity tab, to keep the outside black.

Tried to plug the image file into the default shader's luminosity file input with no success.  It's a PNG with alpha channel.

Been a long evening/night of learning TG2.  Maybe I'll have more success in the morning.

PeanutMocha

Almost have it working now... was overtired and had the nodes plugged wrong.

The only remaining issue... as I  move my plane further and further from the origin, a smaller and smaller portion of the original image appears projected on the rectangle.  I'm pretty sure this has to do with projecting through the render camera, but not sure how to overcome the problem.  Do I need to create a new camera close to the rectangle's final position with the correct orientation and project through that camera?

Hetzen

Yes, create another camera to use as the plane's image projector. Or, if the plane is in a 90 degree angle, you can try and use the XY projectioon type in the image node, which eliminates the need for a camera. Just make sure you type in the plane's dimensions into the image map shader's size, position it at the same location as your plane object.

PeanutMocha

#6
Worked!  I ended up just putting a new camera in front of the plane.

Dune

Great, I'd like to see the result.

PeanutMocha

You can see the result in the background of the pictures with the flowers in the foreground here:

http://terragen2.wordpress.com/2011/04/24/glowing-in-style/

The sky feature is the two dragons "battling" in among the stars.

I'll do a more prominent render of it when I get home tonight.

PeanutMocha

Here's a more prominent rendering of the sky feature "Skydragons".