PDA

View Full Version : Application of Normal Maps



TankCommander
Sep 10 2007, 02:36
Have tried doing a test by first creating a torso in ZBrush3 and exporting the low res mesh and normal map. First I noticed that ingame the normal maps seem to work fine but when the model has no direct light shining upon it there is no detail. Below is an image of the torso in bulldozer but very dark. I figure this may be the base calculation level for the normal maps and as you can see the only detail coming through is from direct light. Having a look at some BIS models this doesn't seem to be the case. Now I've spent several hours trying different combos in the mateditor with not too much luck. So what I am asking is, has anyone conquered this area of arma and normal maps and can they give a sure solution.

Just seems that whatever program it is, normal maps are hard to tame.

ZBrush object
http://img477.imageshack.us/img477/9708/eg001zd8.jpg

Bulldozer
http://img521.imageshack.us/img521/4320/eg002dt2.jpg

Arma model. Notice the parts that are shadowed still hold some normal map detail.
http://img205.imageshack.us/img205/7712/eg003pi1.jpg

Sennacherib
Sep 10 2007, 02:42
you need a specular map to say at the program where must be the lights and the shadows. http://forums.bistudio.com/oldsmileys/smile_o.gif

TankCommander
Sep 10 2007, 03:31
Already has a specular map and have tried others too.. Maybe it's the normal map itself. In that case would be good to know the right values and how to apply those to an already made normal map.

Here is my normal map which was converted from a TGA to PAA via TexView2.

http://img104.imageshack.us/img104/8043/eg004tp9.jpg

ADOGMC
Sep 10 2007, 04:17
create a file rvmat avec Mat editor or text processing.
http://adogmc.free.fr/Images%20forums/Mapeditor.jpg

ex:
<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">ambient&#91;&#93;={1.000000,1.000000,1.000000,1.000000};
diffuse&#91;&#93;={1.000000,1.000000,1.000000,1.000000};
forcedDiffuse&#91;&#93;={0.000000,0.000000,0.000000,0.000000};
emmisive&#91;&#93;={0.000000,0.000000,0.000000,1.000000};
specular&#91;&#93;={0.000000,0.000000,0.000000,1.000000};
specularPower=1.000000;
PixelShaderID=&#34;NormalMapMacroASSpecularMap&#34;;
VertexShaderID=&#34;NormalMapAS&#34;;
class Stage1
{
texture=&#34;ado_armes&#92;QBU-88&#92;qbu88_nohq.paa&#34;;
uvSource=&#34;tex&#34;;
class uvTransform
{
aside&#91;&#93;={1.000000,0.000000,0.000000};
up&#91;&#93;={0.000000,1.000000,0.000000};
dir&#91;&#93;={0.000000,0.000000,0.000000};
pos&#91;&#93;={0.000000,0.000000,0.000000};
};
};
class Stage2
{
texture=&#34;#&#40;argb,8,8,3&#41;color&#40;0,0,0,0&#41;&#34;;
uvSource=&#34;tex&#34;;
class uvTransform
{
aside&#91;&#93;={1.000000,0.000000,0.000000};
up&#91;&#93;={0.000000,1.000000,0.000000};
dir&#91;&#93;={0.000000,0.000000,0.000000};
pos&#91;&#93;={0.000000,0.000000,0.000000};
};
};
class Stage3
{
texture=&#34;ado_armes&#92;QBU-88&#92;qbu88_smdi.paa&#34;;
uvSource=&#34;tex&#34;;
class uvTransform
{
aside&#91;&#93;={1.000000,0.000000,0.000000};
up&#91;&#93;={0.000000,1.000000,0.000000};
dir&#91;&#93;={0.000000,0.000000,0.000000};
pos&#91;&#93;={0.000000,0.000000,0.000000};
};
};
class Stage4
{
texture=&#34;#&#40;argb,8,8,3&#41;color&#40;1,1,1,1&#41;&#34;;
uvSource=&#34;tex&#34;;
class uvTransform
{
aside&#91;&#93;={1.000000,0.000000,0.000000};
up&#91;&#93;={0.000000,1.000000,0.000000};
dir&#91;&#93;={0.000000,0.000000,0.000000};
pos&#91;&#93;={0.000000,0.000000,0.000000};
};
};

[/QUOTE]


insert the way of your two files nohq and msdi inside.
silmutanement select principal texture in the window textures and the key ctrl.
Press on the key E is in the section path Mat writes chement tone RMAt file. Veiled.
Repeat the operation for each texture if you wishes it.

TankCommander
Sep 10 2007, 04:59
Thanx for your help ADOGMC http://forums.bistudio.com/oldsmileys/smile_o.gif

After getting the model to look as best it can without more potential layers I can maybe demonstrate better what I mean about losing normal map detail.

In the picture below I just point out what I can see in Bulldozer. Now compared to the BIS models which seem to have detail in these shadowy bits, this test doesn&#39;t.

One thing I just picked up and haven&#39;t heard of anyone talking about before was the _as.paa files. It seems to be like an ambient light texture which is simply comprised of a shadow map but made such that it&#39;s only seen in shadowy parts. Pretty clever if what I&#39;m interpreting to be right. And with this sort of map I think that might be the best way to maintain some level of fake detail where the sun don&#39;t shine instead of having just a smooth surface where normally it would look detailed and bumpy.

Any thought&#39;s on this

http://img481.imageshack.us/img481/500/eg005py2.jpg


Quick question: some parts on the normal map appear on the model inverted, how can you fix that?

Panda[PL]
Sep 10 2007, 11:01
Quick question: some parts on the normal map appear on the model inverted, how can you fix that?
The correct channel settings for ArmA are:
R = +X
G = -Y
B = +Z

You probably have one channel inverted (or not).

Yes, _as.paa files seem to simmulate the effect of light reflected from surroundings hitting the object.
Maybe try placing ambient occlusion in it and see how it will work.

TankCommander
Sep 10 2007, 13:57
@<hidden> Sep. 10 2007,13:01)]
Quick question: some parts on the normal map appear on the model inverted, how can you fix that?
The correct channel settings for ArmA are:
R = +X
G = -Y
B = +Z

You probably have one channel inverted (or not).

Yes, _as.paa files seem to simmulate the effect of light reflected from surroundings hitting the object.
Maybe try placing ambient occlusion in it and see how it will work.
Any idea how to change these values in photoshop? And yeah my next test object will include some occlusion passes for an extra spiffy result.

Also in programs like ZBrush you only get the option as far as I can tell to flip colours like red, green and blue but will look into it.

Panda[PL]
Sep 10 2007, 14:08
Quote[/b] ]
The correct channel settings for ArmA are:
R = +X
G = -Y
B = +Z


Also in programs like ZBrush you only get the option as far as I can tell to flip colours like red, green and blue but will look into it.
I know. G= -Y means "flip Green". Red and Blue stay normal.
You have all channels set positive (not flipped) at the moment, thus when illuminating from up and down the effects are switched.

I would also advice to use TexView2 to convert to .paa. More reliable.
Or atleast open the ready .paa file with TV2 to see if something weird didn&#39;t happen upon export (channels didn&#39;t get switched etc).

I know .paa plugin is handy, but some people using it get strange results.

Have fun with _as.paa, waiting for results.