PDA

View Full Version : Global Illumination Crazyness


Nerfbat
10-25-2005, 05:08 PM
This is part of a project I'm working on for one of my classes, and is very unfinished. All the geometry is still using the default lambert shader. I just wanted to play with the lighting before I moved on to add more detail and texture the scene. Here's a picture of the basic layout of the scene:
http://portfolio.iu.edu/rbilbrey/wireframe.gif

So after tweaking the GI/Photon settings for a while, with the camera definitely not looking at the door, I get to this:
http://portfolio.iu.edu/rbilbrey/roomisfine.jpg

Then I do a few more renders to see how the rest of the room looks. I turn the camera to discover that the door in my scene is no ordinary door. It is a magical door. It's magical because all magical things glow... yeah..
http://portfolio.iu.edu/rbilbrey/doorGoCrazy.jpg

So my question to you is, why is the door magical and glowing, and how do I make it stop? It's not that I don't like magical glowing doors, honest. That's just not something I was going for.


p.s. - Because you totally can't see the door due to the magical glowing, here's a render using default lighting:
http://portfolio.iu.edu/rbilbrey/noGI.jpg

Jozvex
10-26-2005, 12:02 AM
Maybe the door's normals are inverted?

Is the light inside the room or outside? The door looks a bit like it's being attacked by big fat photons.

Nerfbat
10-26-2005, 12:53 AM
I've tried reversing the normals on the door, but that has absolutely no effect. Nothing changes at all. And, yes, the light is located outside of the room, shining through the slot in the door. I've also tried just putting a poly cube where the door is, and leaving a gap at the top. That's a little better, but something similar still happens near the gap. It looks like normal blowout though, so I'm not entirely closed to the idea that something in my door model is screwy.

I'm really not sure what to do. I'm thinking about using a point light inside the room for GI/bounce light, and just using a standard light outside for the direct light. Still, I'd really like to understand what's going on here. Because, hey, maybe someday I'll want to replicate this crazy glowy door thing...

Thanks for the response btw. :)

slipknot66
10-26-2005, 01:50 AM
Are you using Shadow maps or raytraced shadows? or is the light casting any shadows?
Also check the intensity of the phtons, and check to see if the default light its not on. you can see that under the render settings, Render Options. uncheck Enable Default lights.

Hamburger
10-26-2005, 02:13 AM
When you get blowouts like that try reducing the Irradiance Color to a a darker grey. This is located under the mental ray tab, which is in the material rollout.

Then assign the rest of the room a different shader.

It's just a neat little workaround that you could try, hope it helps.

Jozvex
10-26-2005, 02:31 AM
Also try turning down your GI Radius setting. Maybe photons are hitting the back of the door (which are really bright because the light is right there) and because of a large radius setting, the front of the door's samples are taking info from the super-bright photons on the back of the door.

Nerfbat
10-26-2005, 03:52 AM
Also try turning down your GI Radius setting. Maybe photons are hitting the back of the door (which are really bright because the light is right there) and because of a large radius setting, the front of the door's samples are taking info from the super-bright photons on the back of the door.

Thanks a ton. I'm sure that's what it is now, my photon radius was set pretty high, and yep, it's taking photons hitting the other side of the door and wrapping them around to the front. I even tested it by reducing the number of photons to like 5 and cranking the intensity way up. They're about twice as wide as the door. Oops.

Reducing the photon radius so that doesn't happen is a bit problematic though, because I have to use more photons to compensate, and that shoots my render time through the roof. This is eventually going to be in an animation, so I really can't afford extreme render times.

So... I guess now my goal is to make the bad photons stop hitting the back of the door and making things go crazy.


HamburgerTrain: That's neat, thanks. I didn't know about that. I tried it and, while it made the blowout less extreme, it was still very much there even when the irradiance color was near black.

Slipknot: I'm using raytraced shadows, and the default light is off. Why the shadow question? Could that be somehow contributing to the problem? And.. my photon intensity is approximately "way way high." 150,000,000, if you want a number. Hey, it worked for the rest of the scene.

Jozvex
10-26-2005, 05:21 AM
Some things I might try are:

1. Apply a different shader to the back of the door that is completely black. That way even if the photon-through-the-door thing occurs, black photons won't add any effect to the rest of the lighting.

2. What sort of light is it behind the door? Make it a spotlight with a very focussed cone (focussed at the slit in the door). That way not only less photons will hit the back of the door causing the bad effect, but the rendertime should go down because the right number of photons will enter the room quicker, instead of bouncing out into the solar system, causing more photons to need shooting.

Nerfbat
10-26-2005, 06:26 AM
Thanks so much for the help everyone. The problem evaporated pretty quick once the shader on the back of the door had a totally black irradiance color. Render times went down pretty significantly too from tightening the spotlight's cone up, instead of bouncing most of the photons off into oblivion. Just gotta tweak the GI settings a bit to get the rest of it right again.

Before Jozvex suggested the different shader thing, I tried something else that.. sort of worked. It made me a little curious because of some odd results I got. I basically made a plane, and put it directly in front of the spot light, and cut a hole so the light only went where I wanted it. That actually worked, but I had even more photons bouncing into the great beyond that way, so my render time went up. But the lighting looked totally smooth, pretty much the same as the parts of my scene that weren't messed up before. Just to be clear on what I did here's the plane: http://portfolio.iu.edu/rbilbrey/plane.jpg

Here's the "odd results" part. To stop photons from flying off into nothing, I made a box around the plane/light. Another image for clarity: http://portfolio.iu.edu/rbilbrey/box.jpg For some reason, that drastically reduced the number of photons actually going through the hole in the plane/getting into the room. I'm just a bit curious why putting a box around a plane would change the number of photons that made it through the hole in that plane.

Thanks again, you folks are great. :)

Jozvex
10-26-2005, 06:38 AM
I'm just a bit curious why putting a box around a plane would change the number of photons that made it through the hole in that plane.

Hmm well, when there's only the plane, most of the photons are going into space, then being re-emitted again and again until the right number of photons (as set on the light) actually land on something. Because most of the 'landing space' is through the hole, it eventually gets lots of photons.

When there's a cube around it to catch photons, Mental Ray just goes "oh look, the cube caught 9000 photons which meets the requirement" and then stops. It doesn't care what catches the photons so long as something does. It's just that in this case we couldn't care less if the cube is all nicely photonified, we want them in the room!

cpan
10-26-2005, 07:36 AM
try replacing the default lambert with an DGS_material cause this shader allways give better and faster GI/FG renderings :)


here's one tip to set the correct Photon Intensity and to get physical lighting:
on all your lights, in the mentalray section of the Attribute Editor, plug an mentalray physical_light shader (it's in the mentalray light section of the Create Render Node window) in the Custom Light Shader slot and then adjust the physical light's Color V (V from HSV) to sett your light's intensity. After you find the right intensity, just copy the Color V from the physical_light to the Photon Intensity attrbute and bang you have the correct GI intensity ;)


/p

CGTalk Moderation
10-26-2005, 07:36 AM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.