Game Development Community

Normal maps in Torque 3d

by Jeff Meyer · in Artist Corner · 03/07/2010 (11:24 pm) · 30 replies

I have normal maps applied to a character. They are rendering fine in Max.

They also work fine in TGEA.

However, in Torque 3d they are producing seams.

I'm leaning towards this being a problem with how the tangents are handled in the engine.

Also, these models are being applied in-game through a demo version of the engine. I am unsure what version it is. Is it possible a newer version has dealt with this issue?

Torque advanced image:
jeff-meyer3d.com/download/TGEA_no_seams.jpg
Torque 3d image:
jeff-meyer3d.com/download/T3D_normal_seams.jpg
Troubleshooting:
Rendered new normal maps in a trial and error fashion by flipping the green and red channels in conjunction with changing how tangents are derived.

Rendered new normals in a host of applications such as melody and x-normal with the same result.

None of them are working.

Can someone explain how the tangents are derived in T3D?
Also, if someone has rendered normal maps in z-mapper successfully for the T3d engine, can you please share your settings.

About the author

Ambient Wave Inc is a digital media production company providing web and graphic design services. http://ambientwave.com

Page«First 1 2 Next»
#21
03/16/2010 (7:48 am)
I looked through this post and I didn't see it mentioned (apologies if it was and I missed it) but are your normal maps using Z-up or Y-up?

3DS Max using Z-up normals maps, Torque3D uses Y-up. So if you haven't tried it already, run your normal map through a conversion tool (like the nVidia normal map tool found in photoshop) and see if it resolves your issues.

As for whether or not I have seen these issues. I will give it a try today with some art I have laying around and see how it goes (we aren't at the bling state of our current project so we havent tried them yet).

Logan
#22
03/17/2010 (12:00 am)
Here are the different swizzle settings used in Xnormal:

+x +y +z
+x -y +z
-x +y +z
-x -y +z

+y +x +z
+y -x +z
-y +x +z
-y -x +z

--------------------------------------------------------
None of these render correctly inside Torque3D.

I can render these properly in 3Ds by swapping channels and inverting depending on the swizzle output.
jeff-meyer3d.com/download/max_render.jpg
I think the key to this problem is the previous renders I have posted that show half the face being rendered inverted.

Perhaps a techie can look at those and determine how the calculations are causing that. I've been taking a brute force attempt by trying every combination. Swapping Red and Green channels and flipping each one is not the solution in this case.


#23
03/17/2010 (11:09 am)
Jeff, can you shoot me over the model and the normal map that shows "inverted and properly" on the face ? ..I'd like to take a look at a few things. thx
#24
03/17/2010 (10:20 pm)
Sent.

hopefully, you do not have the same problem in torque3d and we can fix this.
#25
03/18/2010 (8:26 am)
There could also possibly be a lighting bug in T3D that does exist in other engines that can possibly give you the same inverted normal maps though that typically tends to occur due to mirrored geometry. there is mention of it in this tutorial on normal mapping with mirrored UV's but that type of bug usually only occurs on mirrored objects, when looking at the model if you used symmetry or other types of modeling techniques does the location of the flipped normals make sense based on what might have been mirrored across?
#26
03/18/2010 (8:28 am)
Unless Jeff has some insight into that..
That is one of the things I'll be checking for tonight. I won't have time until then.
#27
03/18/2010 (11:13 am)
@ Ken

Unfortunately, I'm not using mirrored Uvs as that would be a prime candidate.

My hope is that something I have done is causing the problem and not the engine itself.

Although, seeing how the map is working corretly in TGEA and also in MAX makes me think otherwise.

In addition, I have used other models that have the same problem which I have not posted screenshots of. Therefore, I am led to believe this is engine specific and not model specific.
#28
03/18/2010 (1:33 pm)
@ Jeff,

engine specific is kind of were I was going with the question, other game engines have issues with lighting a Normal map properly and I am curious if that may be the issue here. Typically in other engines with similar issues the problem was only apparent if geometry (not necessarily UV's but sometimes) were mirrored in the creation process, which is why I was asking if in the process of building the model if you mirrored any geometry or used the symmetry modifier, When i get a chance i was going to try it out on a character i created with that method to see if i can get the same normal errors. all the characters i have been using were not modeled that way and instead were created completely in zbrush and i haven't yet seen that issue, except if i try to import a model directly after using decimation master which requires some remodeling sometimes.

edit: attempted what I was describing and my models still render correctly.
#29
03/18/2010 (6:13 pm)
Jeff. I was hoping for the .max of the model or at least the top half of it.
#30
03/19/2010 (10:38 am)
posting issue in private forum with 1.1beta findings
Page«First 1 2 Next»