View Full Version : Normal Mapped objects cannot be mirrored?
Niber 01-02-2006, 02:32 PM http://www.niber.net/3d/error.jpg
Look what happens in Maya when I mirror over the object, on the right one it looks like the lighting is coming from below.
Now I can fix this for a render by dublicating the same material to the mirrored but flipping the green channel, but I do this as a game exercise so I want to do this whatever way that should work in-game.
Does it not work for games to mirror over NormalMaped objects?
I'm using Maya 7 and JS_normalmapper.
Thanks
\The Nib
|
|
kotter
01-02-2006, 04:04 PM
hey, not too sure about this but mabe you could try flipping the uv-coordinates?
Normal maps allways give me these kinds of troubles... :)
Niber
01-02-2006, 07:44 PM
nah, then I can't use the same UV space for it.
but I think I've solved this, found a tutorial describing normalmapping mirroring.
Could you post a link to the tutorial you mention please?
Niber
01-03-2006, 09:20 AM
link (http://www.poopinmymouth.com/tutorial/normal_workflow.htm)
.
.
.. (blablaaaa)
SHEPEIRO
01-03-2006, 11:16 AM
ive often had similar problems, in max, they deffinatly can be mirrored, its whether it spoils the illusion or not. with this it does, but normally you would get the x co-ords flipped (ie light from left or right directions).
does maya have an Xform reset function? that often helps, or i would create another primitive attach the mirroered section and delete the primitive(or just attach the mirrored to the original)
these should sort out the problem with the vertical direction of the light source, but you still might have probs with the x.
best way is to make stuff rotatable
tin-tin
01-03-2006, 05:37 PM
I used do the same thing in 3ds max 6 flipping green channel on the mirrored object. max 7 and 8 dosn't seem to have those issues like the incorrect lighting on the mirrored half.
Your asking how this will render in a game engine, mirrored ones will look fine in doom3 engine, i think its engine specific some can do mirrored uv's some can't. You could tile the uv's, not sure this is done.
Confracto
01-03-2006, 05:42 PM
actually tin, I still had to flip the green on an object in max 8.
but really, another solution is just to flip the green channel in the texture itself, and make a new file. double's texture size, but it works, and you don't have to make each half seperatly.
Confracto
01-03-2006, 05:44 PM
actually tin, I still had to flip the green on an object in max 7.
but really, another solution is just to flip the green channel in the texture itself, and make a new file. double's texture size, but it works, and you don't have to make each half seperatly.
tin-tin
01-03-2006, 09:23 PM
I'm pretty sure mirrored normalmaps work in max 7 and 8, I use the normalbump then turn on display in viewport. I've read somewhere on the autodesk website resolving those issues.
Wait I'll do a quick test to see...
tin-tin
01-03-2006, 10:07 PM
Here is a simple test i did, the object here is a capsule with a normalmap applied. Only half the object is normalmaped the other half is mirrored, the capsule on the right shows the line of symetry, with the omni light lighting both object in the center which clearly shows the correct lighting on both sides. The only downside of mirroring is the faint seam across the middle.
powerACE
01-04-2006, 02:33 AM
this is one problems i encounted before, in using normal maps you must not mirror the model or it will flip but according to the new game development technologies using the unreal engine they can double the texture requirement generating 1-2 normal maps of resolution 2048x2048 per character which you must make the UV coordinates of the entire mesh body but i think it is a good technique so that both left and right sides of the model don't have to be symmetrical it is good for creativity.
To fix your problem you can just make another copy of the texture map (which makes you have 2 maps) and the mirrored model. Flip the UV coordinate of the mirrored object and reimport the flipped normal map ..
Not sure if this helps anyone but you can get a shader to invert the red or green channel of your normal map if you add other conditions to the shader.
I've done some tests where I've modified a shader to use the vertex alpha value to control inverting the green channel. If the vertex alpha was above 0.5 the green channel was in the normal range 0 to 1, if the alpha channel was below 0.5 I inverted the channel (1 - the channel value). This ment in 'flipped' sections of a model seting the vertex alpha below 0.5 corrected the inverted normal mapping.
As I understand it adding an 'if' statement to a shader makes it much less efficient, I guess it may be useful in some circumstances though.
Jol
CGTalk Moderation
01-04-2006, 09:11 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.
vBulletin v3.0.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.