PDA

View Full Version : Normal map problems


j5ive
09-04-2006, 08:47 PM
I'm trying to normal map the face of a character and having probs, see attached the uv layout of the low poly face, and the resultant normal map. any ideas why the map is as it is,? I'm really stuck on this, this is my first attempt at normal mapping a character.

j5ive
09-04-2006, 09:30 PM
Any ideas??

iLegacy
09-04-2006, 09:33 PM
- HighPoly - Model cuts the LowPoly - Model?
- Invert normals at the LowPoly - Model?

Maybe it would help to post screenshots out of your scene and the used tools.

j5ive
09-04-2006, 09:51 PM
Ok, I'm using Maya 6.0 the transfer surface information. I have used pretty much all variables under the settings and still similar output. Heres the scene with the two heads apart.

BigErn
09-04-2006, 10:00 PM
Looks to me like the kind of wacky colours you get when the envelope you use is too big, so your env gets overlapped then makes a strange normal. If you have 1 mesh you might have to do the normals in parts, if some bits of the model need a big env size, like 3 and others just need 0.5. Then just combine them in PS. :thumbsup:

j5ive
09-04-2006, 10:04 PM
Thanks for the heads up, I reversed the normals on the low poly like suggested and it has worked to an extent, the map looks good, though it is very poorly lit now, is this normal? heres a rendered shot. Apologies for these remedial questions hopefully i'll have a better understanding of normal maps hereafter.

heres a render of what i have now with the normals reversed on the lower poly and map applied

iLegacy
09-04-2006, 10:04 PM
When i have such problems, i start testing with more simple objects like a sphere or something to get more information about the cause of the problem.

iLegacy
09-04-2006, 10:14 PM
To better understand normal maps read this normal-map-tutorial:

http://www.bencloward.com/resources_tutorials.shtml

and this:

http://www.poopinmymouth.com/tutorial/normal_workflow.htm

JYoung
09-05-2006, 12:41 AM
Thanks for the heads up, I reversed the normals on the low poly like suggested and it has worked to an extent, the map looks good, though it is very poorly lit now, is this normal? heres a rendered shot. Apologies for these remedial questions hopefully i'll have a better understanding of normal maps hereafter.

heres a render of what i have now with the normals reversed on the lower poly and map applied

Yes, that's normal for a rendered normal map in maya 6(and 7). Straight out of the box, maya won't render normal maps correctly so you need a specialized shader network to tell it how to handle a normal map during render. Most people, me included, seem to use the jsnormal shader available at http://www.pixero.com/downloads.html with good results. You may have to flip the x,y,z or r,g,b channels within the shader to get it to render correctly, so just play around with it.

j5ive
09-05-2006, 08:36 PM
Hi, I've downloaded the Js_normal mapper, but can't fathom out what to do with it, anyone any ideas or used it before? Please help.

Regards

Mike

JYoung
09-05-2006, 10:01 PM
If I remember correctly there's a readme file telling you how to set it up. I'll do a writeup when I get home if you can't figure it out.

j5ive
09-05-2006, 10:21 PM
Cheers Jason, that would be great if you don't mind. There is a short readme file though it has been updated with bug fixes etc, and is entwined with the edge shader instructions as well whichis making it more the confusing for me to follow, and I'd sooner not copy and paste files into folders without knowing 100% that it is correct.

Thanks Again!

rasmusW
09-05-2006, 10:48 PM
hey mike!

i once did a small and very easy tutorial on normal-mapping in maya. http://forums.cgsociety.org/showthread.php?t=268417
-it should work fine in both v6 and v7... hope it helps.

-r

j5ive
09-05-2006, 11:00 PM
cheers abyss, ill take a look tomorrow, just closed maya down and ready for bed.

Thanks for your help guys, :)

JYoung
09-06-2006, 04:16 AM
Abyss, how is that any different than the usual outColor>normalcamera technique? When setting it up that way, it doesn't appear to render correctly.

Mike, the pertinent info from the jsnormal info file is as follows:

1. Install the .dll in your maya/mentalray/lib folder
2. Install the .mi in your maya/mentalray/include folder
3. Install the .mel in your My documents\maya\6.5\scripts folder
4. Install the .xpm in your My documents\maya\6.5\prefs/icons folder
5. Install the .fti in your Program files\Alias\Maya6.5\icons
6. Add these lines to your maya.rayrc file:
link "{MAYABASE}/lib/JS_NormalMapper.{DSO}"
mi "{MAYABASE}/include/JS_NormalMapper.mi"

You will find JS_Normalmapper under textures and JS_EdgeDisplacer under displacement in you custom MentalRay nodes.

The following files come with the zip file.
1. The .dll file is found in lib>windows>JS_NormalMapper.dll
2. The .mi file is found in include>JS_NormalMapper.mi
3. The .mel file is found in scripts>AEJS_NormalMapperTemplate.mel
4. The .xpm is found in icons>render_JSNormalMapper.xpm
5. The .fti file is found in icons>Js_NormalMapper.fti
6. My maya.rayrc file was found in C:\Program Files\Alias\Maya7.0\mentalray Yours should be in a similar location. Open it with a text editor and add the lines as outlined in step 6 above. Mine ended up looking something like this:

registry "{MRMAYA_START}"
link "{MAYABASE}/lib/base.{DSO}"
link "{MAYABASE}/lib/physics.{DSO}"
link "{MAYABASE}/lib/mayabase.{DSO}"
link "{MAYABASE}/lib/contour.{DSO}"
link "{MAYABASE}/lib/subsurface.{DSO}"
link "{MAYABASE}/lib/paint.{DSO}"
link "{MAYABASE}/lib/mi_openexr.{DSO}"
link "{MAYABASE}/lib/mayahair.{DSO}"
link "{MAYABASE}/lib/JS_NormalMapper.{DSO}"
mi "{MAYABASE}/include/mayabase.mi"
mi "{MAYABASE}/include/base.mi"
mi "{MAYABASE}/include/physics.mi"
mi "{MAYABASE}/include/contour.mi"
mi "{MAYABASE}/include/subsurface.mi"
mi "{MAYABASE}/include/paint.mi"
mi "{MAYABASE}/include/mayahair.mi"
mi "{MAYABASE}/include/JS_NormalMapper.mi"
echo "mental ray for Maya - startup done"
end registry

Notice the lines in bold. Those will be the ones you add. That should be all you need to get it setup. Once added, the shader will be found under the textures tab in hypershade(make sure it's displaying mental ray nodes). There's a menu on the left side above all the nodes that will say "Create Maya Nodes", "Create Mental Ray Nodes", or "Create All Nodes". It needs to be either on create mental ray nodes, or create all nodes. You will still create a shader(blinn,lambert, etc) that is assigned to your object. Press the JS_NormalMapper button and it will create a node in your work area. Doube click on that to bring up the attribute editor and click on the normal map checkered button so you can add your normal map file. Now middle mouse click the JSnormal node in the work area and drag it to your shader to bring up the connection editor. Click on the Out Value on the left side, and the Normal Camera on the right side. You should be good to go.

Things to keep in mind. At least on my comp, in the viewport, my models look really crazy when using this shader. However, they look as they should once rendered out. Also, you may need to flip the x,y,z or r,g,b channels within the jsnormal attribute editor. This will come in handy when using normal maps created by various programs(say zbrush, etc) where the normal maps they create may not be oriented correctly for maya.

Hope that helps. I know it seems long, but once setup, there's very little work involved, and the results are nice. Let me know if you have any more questions.

rasmusW
09-06-2006, 08:34 AM
Abyss, how is that any different than the usual outColor>normalcamera technique?

don't think it's any different. just thought i'd help.
i'm not a games modeler, so i don't know if it's the best way. it just worked out fine for me.

-r

j5ive
09-07-2006, 09:03 PM
ok, I've done as you've said and after applying the jsmapper i got this strange effect in my viewport, ive tried to flip the xyz channels though they don't change much. Any ideas?

CGTalk Moderation
09-07-2006, 09:03 PM
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.