Sign in to follow this  
luca-deltodesco

normal map, reflective/refractive artifacts

Recommended Posts

im messing around with ray tracing, and have normal mapping and reflection/refraction modelled, the problem is that artifacts are arising in the reflections and refractions due to the normal mapping at certain angles. heres an image explaining what the problem is: http://img225.imageshack.us/my.php?image=fucksakecs1.jpg black is the current ray. green is the surface normal, and the dark blue is the surface normal after the normal mapping is applied. Now as you can see, the ray is being reflected off the surface, but because of the directions of the ray and normal, its being reflected into the surface which makes no sense as far as the ray tracer is concerned. what is the best approach to deal with this? what is currently happening, is this happens as it does then engine then assumes that all has gone as planned, and will therefore start reflecting the ray inside of the object, and if it exceeds the number of allowed rays it will colour the pixel black, otherwise this might happen again inside of the object allowing it to leave the object, and the pixel will be coloured falsely.

Share this post


Link to post
Share on other sites
I'm not 100% sure, but that normal haven't to be visible, because dot product between current ray and normal (after normal mapping) is less than zero. Anyway, if it's still visible (but it hasn't to be!), when you're tracing, try to use parllax mapping (solution isn't so hard, even for raytracing - it'll "clear" these kind of effect). You could try even something harder method, how to achieve parallax effect (like Interval Mapping, Parallax Occlusion Mapping, Steep Parallax Mapping or Relief Mapping).

Anyway reflecting rays inside objects would probably result just in something-like sub surface scattering, not reflecting.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this