project-navigation
Personal tools

Author Topic: Normalmapping Questions...  (Read 9569 times)

Offline MCR

  • PHALANX veteran
  • ******
  • Posts: 1244
    • View Profile
Normalmapping Questions...
« on: April 10, 2010, 06:04:03 pm »
Okay, I think I have checked now how to make great detailed normalmaps. But as I understand UFO:AI needs the height to be encoded in the alpha channel. With the normal 'overlay' method of normalmap creation (2nd normalmap tutorial in the wiki) I get the texture attached as 1st picture.

When I do transfer color to transparency afterwards I get the second attached picture.

Is this the correct way for encoding the height into the alpha channel so parallax mapping will work correctly in UFO:AI ?
If not, how do I get the height correctly encoded into the alpha channel of the normalmap ?

Offline Mattn

  • Administrator
  • PHALANX Commander
  • *****
  • Posts: 4831
  • https://github.com/mgerhardy/vengi
    • View Profile
    • Vengi Voxel Tools
Re: Normalmapping Questions...
« Reply #1 on: April 10, 2010, 06:12:15 pm »
i'm using the gimp normalmap plugin [1]

first i'm converting the textures into greyscale, flatten them and remove almost all of the noise that is left (otherwise the surface won't look good)

after the heightmap is looking good i'm calling the normalmap plugin and selecting the appropricate height source. Of course you can also split the channels and edit the alpha channel along.

--
[1] http://nifelheim.dyndns.org/~cocidius/normalmap/

Offline MCR

  • PHALANX veteran
  • ******
  • Posts: 1244
    • View Profile
Re: Normalmapping Questions...
« Reply #2 on: April 10, 2010, 07:18:26 pm »
Thanks, Mattn, but this does not really help me  ???.
I also use the normalmap-plug-in, but after using it on the greyscale-heightmap I do not automatically have the height encoded in the alpha-channel  :P  :-\
Could you tell me if I have to adjust the plug-in so that 'Alpha Channel: Height' is displayed ?
Maybe you could look @ the normalmaps I posted here & tell me what I did wrong...
I wanna use the overlay-method described in the second tutorial link about normalmapping to get some really cool normalmaps, but first I need to know how to make them perfectly suited for UFO:AI to not waste any time...
First experiments look great, but I am quite sure that still I do not make everything perfectly suited for UFO:AI...
Best for me would be a screenshot with the correct settings for the plug-in if you could manage to get me that one  ;)

Offline MCR

  • PHALANX veteran
  • ******
  • Posts: 1244
    • View Profile
Re: Normalmapping Questions...
« Reply #3 on: April 10, 2010, 07:20:59 pm »
btw, this pjrock picture I chose for the tests had VERY bad quality to start with, so this are only experiments & the normalmap has the same quality...

Offline Mattn

  • Administrator
  • PHALANX Commander
  • *****
  • Posts: 4831
  • https://github.com/mgerhardy/vengi
    • View Profile
    • Vengi Voxel Tools
Re: Normalmapping Questions...
« Reply #4 on: April 10, 2010, 08:49:10 pm »
does your heightmap already has an alpha channel? if not, the plugin won't offer teh option to add the height to the alpha channel

Offline Mattn

  • Administrator
  • PHALANX Commander
  • *****
  • Posts: 4831
  • https://github.com/mgerhardy/vengi
    • View Profile
    • Vengi Voxel Tools
Re: Normalmapping Questions...
« Reply #5 on: April 10, 2010, 08:59:48 pm »
add to the wiki article

Offline MCR

  • PHALANX veteran
  • ******
  • Posts: 1244
    • View Profile
Re: Normalmapping Questions...
« Reply #6 on: April 10, 2010, 10:13:33 pm »
does your heightmap already has an alpha channel? if not, the plugin won't offer teh option to add the height to the alpha channel

So as I understand I have to first add an alphachannel to the greyscale heightmap !?

add to the wiki article

Thanks for this. This clarifies a lot. But to be 100% sure I will make some examples for review first before starting my serious work on this subject... ;)

I just wanna also note here that with the overlay method revealed in the second wiki normalmap tutorial (http://cgtextures.com/content.php?action=tutorial&name=normalmap) we can make some awesome looking bumpmaps ;)
I would encourage everyone interested in normalmaps to check this one out...

Offline MCR

  • PHALANX veteran
  • ******
  • Posts: 1244
    • View Profile
Re: Normalmapping Questions...
« Reply #7 on: April 14, 2010, 08:05:08 pm »
I made a seamless (@ least so seamless as the original file) normalmap of wall002 in base/textures/tex_buildings_snow using different methods.

I found out the best effect has the one I made using multiple greyscale heightmap overlays & using the normalmap plug-in without using the alpha-channel for the height & to use the command color to transparency in the final step before saving, as the 'encode the height in the alpha channel' normalmap method seems to not work quite well when using multiple overlays...

Could someone test this & if it is okay, I will make normalmaps for all the files in this folder & maybe correct also the textures there to make the visible seams disappear...

(You can test it by starting Skirmish->Industrial Static, it is one of the textures used in the old building right next to the dropship...)

btw, this is a test version with 'only' 20 layers. The final versions will have 30 layers @ least ;)

« Last Edit: April 15, 2010, 07:59:04 am by MCR »

Offline Mattn

  • Administrator
  • PHALANX Commander
  • *****
  • Posts: 4831
  • https://github.com/mgerhardy/vengi
    • View Profile
    • Vengi Voxel Tools
Re: Normalmapping Questions...
« Reply #8 on: April 14, 2010, 09:08:25 pm »
texture isn't working (crc error)

Offline MCR

  • PHALANX veteran
  • ******
  • Posts: 1244
    • View Profile
Re: Normalmapping Questions...
« Reply #9 on: April 15, 2010, 08:02:13 am »
 :-[
Sorry, will maintain my system today, cannot work like this, 4 of 5 uploads I make, are corrupted... >:(
Do not know what causes this exactly @ the moment, but I will eliminate this FX#*%%ยง"&/....

Offline Mattn

  • Administrator
  • PHALANX Commander
  • *****
  • Posts: 4831
  • https://github.com/mgerhardy/vengi
    • View Profile
    • Vengi Voxel Tools
Re: Normalmapping Questions...
« Reply #10 on: April 15, 2010, 08:57:32 am »
looks ok - please upload in higher resolution to let me test in-game

Offline MCR

  • PHALANX veteran
  • ******
  • Posts: 1244
    • View Profile
Re: Normalmapping Questions...
« Reply #11 on: April 15, 2010, 09:10:20 am »
This is the same resolution as the original texture has 256x256, so  ???

Offline MCR

  • PHALANX veteran
  • ******
  • Posts: 1244
    • View Profile
Re: Normalmapping Questions...
« Reply #12 on: April 15, 2010, 09:18:06 am »
Here is the heightmap with the additional overlay layers I based this work on (xcf.bz2):
3 times the size to make it seamless ;)
& doublechecked, working...
« Last Edit: April 15, 2010, 09:19:58 am by MCR »

Offline MCR

  • PHALANX veteran
  • ******
  • Posts: 1244
    • View Profile
Re: Normalmapping Questions...
« Reply #13 on: April 15, 2010, 09:23:45 am »
& this happens with the normalmap, when using the 'correct' method & encoding the height into the alpha channel via the normalmap plug-in. The normalmap looks good, but the effect in-game does not  :-\
You can test this also, but it somehow does not look good ?!
But using 30 or more layers with the other method should enable us to make very detailed nms  ;)...

You could tell me also, Mattn, which textures have the highest priority for you to get some nice nms. I was thinking about basedefend or especially the alienbase  ;)

& if you had not read this:

https://sourceforge.net/tracker/?func=detail&aid=2986651&group_id=157793&atid=805245

Maybe you could give me a short answer, if I can extract that information somewhere (low priority) ;)
« Last Edit: April 15, 2010, 09:30:19 am by MCR »

Offline MCR

  • PHALANX veteran
  • ******
  • Posts: 1244
    • View Profile
Re: Normalmapping Questions...
« Reply #14 on: April 15, 2010, 09:31:50 am »
Thanx.