PDA

View Full Version : Light specularity = jagginess?


Lightweight
08-17-2010, 03:07 AM
I'm modelling a cellphone and Im in the phase of lighting it and trying out things. However, I've run into some strange problems I havent seent before.

This is my setup:

Using Mental Ray
Only mia_material_x on the objects in the scene
"production" quality preset, 2x antialiasing that is.
4 spotlights and some of them have specular enabled.
The spotlights use raytrace shadows with a 1.0 light radius, 10 shadow rays and ray depth limit of 1.

When I render the phone (using a HDR for reflections only, with no FG enabled), the specularity sent out from the spotlights leave a strange jagged line along the side of the mesh.


http://img295.imageshack.us/img295/7572/specularjagginess.jpg

On the left pic, the specular is enabled on all 4 lights, and you can clearly see the jagginess. On the right picture, the spec is turned off on 2/4 lights, and you can see the difference.

check the fullsize for more detail (http://img295.imageshack.us/img295/7572/specularjagginess.jpg)


I've tried:

cranking the antialiasing to more than x2
lowering the anti-aliasing contrast from 0.1 to as low as 0.01
turning up shadow rays to like...crazy levels and no change
using different renderfilters like mitchell and others.

Im rendering at 1080p and full quality and I still get these jaggy lines. Can anyone shed some light on what I can do to fix this?

Lightweight
08-17-2010, 09:57 PM
no tips whatsoever? :sad:

TaKIKO
08-17-2010, 10:40 PM
Are you viewing the render at its actual size?

japetus
08-17-2010, 10:44 PM
This also happens to me too when rendering cell phones funnily enough ;). I think it has to do with really hot reflections/specular on very thin edges of geometry such as panel lines. I'd recommend either turning down or off the specular effect of the offending lights or maybe giving that inner edge a non specular material. The only other way around it I've fond (I use brazil) is to increase the render dimensions until it goes away.

qrichardson
08-17-2010, 10:52 PM
also.. what kind of alpha channel are you rendering in your image. If it is straight and not premultiplied, things can look jagged until comped.

Lightweight
08-18-2010, 02:07 AM
Are you viewing the render at its actual size?

Yes it's at full size.

The only other way around it I've fond (I use brazil) is to increase the render dimensions until it goes away.

Render dimensions, do you mean the resolution or what?

also.. what kind of alpha channel are you rendering in your image. If it is straight and not premultiplied, things can look jagged until comped.

The project is currently rendered with RGBA (byte) 4x8 bit. gamma 1.0, colorclip set to Raw.

I assume thats the info you're looking for, but if not, where do I find it in Maya?

Regards

joie
08-18-2010, 10:07 AM
Do you use mia_roundcorners on your shader?, Have you tried to change the specular balance of the shader to just reflect the light instead of getting the specular component (means more render time, but helps with this kind of problems)?.

Lightweight
08-18-2010, 11:00 AM
Do you use mia_roundcorners on your shader?, Have you tried to change the specular balance of the shader to just reflect the light instead of getting the specular component (means more render time, but helps with this kind of problems)?.

I didnt use roundcorners on the shader. I am simply previewsmoothing it by the normal amount of x2. I tried smoothing it and not using previewsmooth but same results.

Also, I turned down the Specular Balance as well, which diminishes the problem, but the rest of the mesh looks really dull when I do that.

I feel like I've tried everything here :O

joie
08-18-2010, 12:03 PM
What kind of light do you use?, Do you use mental ray shaders for the lights?.

Lightweight
08-18-2010, 12:56 PM
What kind of light do you use?, Do you use mental ray shaders for the lights?.

Im using regular spotlights. Haven't applied anything fancy to them. Basicly I've only applied ray trace shadows to them.

TaKIKO
08-18-2010, 03:06 PM
What is your sampling filter? Try Gaussian.

Check out this topic , seems like he was having the same problem.

http://forums.cgsociety.org/showthread.php?t=857245

joie
08-18-2010, 03:26 PM
You should use mental ray shaders on lights, specially when working with mia materials..., try to use portal lights or physical lights and see what happens.

InfernalDarkness
08-18-2010, 05:02 PM
You should use mental ray shaders on lights, specially when working with mia materials..., try to use portal lights or physical lights and see what happens.

I agree with Joie. You shouldn't be getting ANY specularity with the mia_materials, as specularity is a deprecated function of the old Blinn/Phone fake reflections model of shader. What you should be getting is outright REFLECTION, and your Maya lights aren't going to be helpful with this.

Try MR Area lights instead and/or Portal Lights.

japetus
08-18-2010, 05:31 PM
Render dimensions, do you mean the resolution or what?



Sorry yeah I meant the resolution :hmm:

MasonDoran
08-19-2010, 12:57 AM
I am going to make the wild suggestion that perhaps you should turn on "jitter" in the render globals.

Lightweight
08-19-2010, 06:04 AM
I agree with Joie. You shouldn't be getting ANY specularity with the mia_materials, as specularity is a deprecated function of the old Blinn/Phone fake reflections model of shader. What you should be getting is outright REFLECTION, and your Maya lights aren't going to be helpful with this.

Try MR Area lights instead and/or Portal Lights.

Do you mean that the attribute "specularity" shouldn't even exist when using mia_materials? I can see it in realtime with IPR depending on where I put my lights. Although, now that you mention it, a pass-render I set up real quick wont show any specularity in its pass at all. I dont quite get it though, if it isn't specularity, the highlights that is, then what is it? It isn't reflection, as a refl.pass also turned out as completely black.

Also, I kind of solved the problem with the jagginess by turning on "jitter" in the render globals, thanks to you Mason, so the main problem is solved.
Now I'd just like to know in what pass the highlights from the spotlights will show up in, since it's neither specularity nor reflection.

Thanks a bunch to everyone that took the time to help me out.

joie
08-19-2010, 07:59 AM
I always have jitter ON, you may do so too, it helps a lot when dealing with AA artifacts...

Galakgorr
08-20-2010, 03:40 AM
try using reflector cards instead of specular highlights. make a rectangle, put a surface shader on it, apply a UV ramp with a superbright center and black on the outside. make it visible only in reflections. you'll get way more realistic results than you would with specular highlights, with the added benefit of no noise. i've never trusted specular highlights in mental ray...

djx
08-20-2010, 09:12 AM
Lightweight: Are you using mia_material_x_passes?

David

Lightweight
08-20-2010, 01:10 PM
Lightweight: Are you using mia_material_x_passes?

David

No just mia_material_x

However I kind of solved the jagginess problem by enabling Jitter, but im still trying to figure out the passes/spec/reflection thingy.

joie
08-20-2010, 02:46 PM
Well, you know mia_x give black passes didn't you?, so you'll have to use mia_x_passes for that.

Jozvex
08-21-2010, 11:54 AM
I agree with Joie. You shouldn't be getting ANY specularity with the mia_materials, as specularity is a deprecated function of the old Blinn/Phone fake reflections model of shader. What you should be getting is outright REFLECTION, and your Maya lights aren't going to be helpful with this.

Try MR Area lights instead and/or Portal Lights.

Well I'm afraid this is not true even in Maya 2011. The Mia materials by default do indeed still use fake specularity as well as reflection. Here's a render:

http://www.jozvex.com/images/miaSpecular.jpg

Specular Balance is found under the 'Advanced' section of the Mias and unless you turn it off you still get fake specular as shown above. I'm lighting that highly attractive object with two Maya point lights set with quadratic falloff, and you'll get exactly the same result using the mental ray physical light shader (which is just a Maya light with the falloff locked to quadratic).

Fake specular lives on!

And just by the way, this led me to realise that you can't type in colour values over 1000 in Maya 2011!! I've reported it as a bug but I'm sure it's already known (I hope!). :scream:

Lightweight
08-29-2010, 04:34 AM
I've been too busy to even respond to this thread, but thank you all for the inputs. It's true what my teacher said once; you learn a little bit every time you visit this site. =)

Anyways, here are the results of this project now that Im done:

http://www.cambranddesigns.com/images/Aino_tripple.png

Fullsize: http://www.cambranddesigns.com/images/Aino_tripple.png


http://www.cambranddesigns.com/images/Aino_DoFlighter.png


Fullsize @ http://www.cambranddesigns.com/images/Aino_DoFlighter.png

Somewhat happy with the results. Perhaps I'll try to match it into a real photo to see how it holds up against realism :P

CGTalk Moderation
08-29-2010, 04:34 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.