Author Topic: photoshop cs2 and normal map plugin  (Read 17766 times)

0 Members and 1 Guest are viewing this topic.

Offline Herra Tohtori

  • The Academic
  • 211
  • Bad command or file name
Re: photoshop cs2 and normal map plugin
One issue that hasn't been touched yet and which I discovered semi-accidentally.

If you have any extreme values in either red or green channel, they will "burn through" in FS2_Open, creating nasty nasty black flecks to appear on the surface of the ship.


What this means is that you will need to look out for overcontrasting the image, since if red or green channel values are either zero or 255, black flecks will appear. If you meet this issue, simply reduce the contrast by a low amount like three or five units.


For example, colour [0,255,128] (#00ff08) will result in black flecks, while colour [2,253,128] (#01fe08) will not.
There are three things that last forever: Abort, Retry, Fail - and the greatest of these is Fail.

 
Re: photoshop cs2 and normal map plugin
ok yeah im seein the black spots all over the seams. I'll mess with that later on as its now 4AM and im tired and goin cross eyed =p Btw thanks to both of you for all of the juicy info. The channel thing worked like a charm so later on i'll fix the contrast thing and post an update... oh do i adjust the contrast pre or post filter?

 

Offline Herra Tohtori

  • The Academic
  • 211
  • Bad command or file name
Re: photoshop cs2 and normal map plugin
ok yeah im seein the black spots all over the seams. I'll mess with that later on as its now 4AM and im tired and goin cross eyed =p Btw thanks to both of you for all of the juicy info. The channel thing worked like a charm so later on i'll fix the contrast thing and post an update... oh do i adjust the contrast pre or post filter?

After applying the normal map is the best time in my opinion.

Simply probe the colours at the strongest parts of the image. If either red or green channels has 100% intensity, reduce the contrast by a few steps to bring it down to something like 99% or 98% (the difference between these two is not meaningful).

After adjusting contrast, make sure that the level ground (either [127,127,255] (#7f7fff) or [128,128,255] (#8080ff) ) is still the same colour, otherwise you will end up with the neutral ground of your normal map actualyl tilting the normals of the ship slightly, which is obviously not intended. With small enough contrast change you should be fine on this regard as well, but it never hurts to check.

I think I remember someone saying that FS2_Open uses #7f7fff as neutral colour on the normal maps, but I'm not completely sure. The difference to #8080ff is so small though that it doesn't really matter most of the time, but it would be nice to have this info confirmed.
There are three things that last forever: Abort, Retry, Fail - and the greatest of these is Fail.

 
Re: photoshop cs2 and normal map plugin
However, there is one slight problems with all this, it's a tiled texture and because of that, it's at the mercy of however the tiles are positioned on the given ship and they wont all be placed down the same. SO this x.y and z stuff while all excellent information, wont be worth much if the tiles are places pell-mell all over the CG model.
Got Shivans? The SOC Ezechiel is the schnitzel! Don't leave base without it.

 

Offline Herra Tohtori

  • The Academic
  • 211
  • Bad command or file name
Re: photoshop cs2 and normal map plugin
However, there is one slight problems with all this, it's a tiled texture and because of that, it's at the mercy of however the tiles are positioned on the given ship and they wont all be placed down the same. SO this x.y and z stuff while all excellent information, wont be worth much if the tiles are places pell-mell all over the CG model.


Ah, but what the shaders do can be described as magic and what they do is even better. In other words they deal with the aforementioned problem just fine - in fact they are designed to do just that. The normalmap, be it tile texture or something else, can be aligned any way in the UV-map - even tiled criss-crossed in relation to each other in other parts of the ship - and the game figures out how it's supposed to adjust the lighting. ;7
There are three things that last forever: Abort, Retry, Fail - and the greatest of these is Fail.

 
Re: photoshop cs2 and normal map plugin
I kept looking all over the texture and i saw no extreme colors, granted its difficult to sample every single pixle but i did discover something...




I closed the normal map and re opened it, at first glance its purpleish in color as if the channels weren't managed manually. The red and blue channels are not blacked out and the whole thing is grossly distorted. (see left) The one on the right is a fresh filtering pre saving (no channel management)

i have a feeling what the problem is its being filtered a 2nd time when i save it... how to fix0r?

i saved as a dxt5 ARGB

edit*

interestingly enough if i dont do any channel management and save as a dxt5_nm after filtering, the resulting file is crisp like its sposed ta be
« Last Edit: November 28, 2008, 12:24:57 pm by Vertigo 7 »

 

Offline Herra Tohtori

  • The Academic
  • 211
  • Bad command or file name
Re: photoshop cs2 and normal map plugin
i have a feeling what the problem is its being filtered a 2nd time when i save it... how to fix0r?

Yeah it seems it's performing a normal map filter upon save. Dunno how that's possible... :rolleyes:

I have no experience about the Photoshop DDS plugin, but if you save the channel managed (ie. greenish) file to basic DXT5 (should be RGBA, not ARGB. I don't even, have that option available on GIMP DDS plugin...) it should by all rights save the file correctly.

If all else fails, aquire the NVidia DDS Utilities including the command-line dds texture converter nvDXT. Then save the channel managed file as TGA, and convert it to dxt5 via command line. :blah:


Quote
interestingly enough if i dont do any channel management and save as a dxt5_nm after filtering, the resulting file is crisp like its sposed ta be

Yes, well, might be. But you should be able to manage the channels manually just as well and save it to dxt5 without any distortions.


You might want to try if it's applying the normalmap filter to any file you try to save as dxt5. Otherwise, I don't know what's up with that. :blah:
There are three things that last forever: Abort, Retry, Fail - and the greatest of these is Fail.

 
Re: photoshop cs2 and normal map plugin
I think the RGBA and ARGB are the same thing, i only have the ARGB option in PS... i'll try the command line method, from what i've read some people prefer to do it that way instead. i'll update the results...

btw the dxt5_nm file i just saved had no black specks when rendered in game so that leads me to believe the specks were the result of the 2nd filter being applied (plus the mapping looked like smashed ass =p)

 

Offline Herra Tohtori

  • The Academic
  • 211
  • Bad command or file name
Re: photoshop cs2 and normal map plugin
That's probably what's happening.

Btw:

There are three things that last forever: Abort, Retry, Fail - and the greatest of these is Fail.

 
Re: photoshop cs2 and normal map plugin
  :lol:


and the resulting command line converted file  :eek:










I r making normal mapz0rs!  :D

 

Offline Herra Tohtori

  • The Academic
  • 211
  • Bad command or file name
Re: photoshop cs2 and normal map plugin




Quote


I hope the lack of alpha channel is because it's a jpg file...  :p

May I suggest you try PNG format for images such as these? It's lossless and for images such as normal maps it can be very close contest between jpg and png in file sizes...
There are three things that last forever: Abort, Retry, Fail - and the greatest of these is Fail.

 
Re: photoshop cs2 and normal map plugin
bah i didn't make the texture  :P I just picked this one cuz it seemed simple enough to make a normal map =D my texture artistry skills are the sux. mostly cuz i don't know photoshop all that well. and i converted to jpg (yes theres an alpha =p) for the sake of uploading it

now i may try to fix the texture but my gods i don't wanna get into UV mapping in case there's an issue :P LU is my bane

 
Re: photoshop cs2 and normal map plugin
All good work people! Keep em going as many who have not (and even us who have) created this stuff are finding it good reading.
Got Shivans? The SOC Ezechiel is the schnitzel! Don't leave base without it.