PDA

View Full Version : Alpha maps VS Booleans ( small guide)


Johny
27-12-2004, 05:49 PM
Hello everione im gonna discuss something that i see pretty ussualy on modeling in realtime is that people tend to use loads of time boolean, yes, booleans, that compound object very usefull in 3ds max that cuts an object in another thru a simple click....BUT BEWARE , its easy, yes , the mesh LOOKS clean , BUT apply another boolean modifier, but without changing anything ( means dont subtract, nor nothing ) , now look at your mesh...is it clean ??

- i dont think so...

What is an alpha map ( i will not explain this in technical language, but in a way someone understands it ) :

- alpha maps are a division on a channel of a texture, that can be saved in tga format or any other format that supports multiple channels , you can also save it in jpg, since you will be using it in max as a demonstration .

- if you place in max ( dont worry it also works on games , cause EVERY game supports alpha maps..except some really old ones :P ) in the OPACITY bar of a standard material

http://img135.exs.cx/img135/3346/helpone8qa.gif

where "sfds" its the alpha map , that in this case is this image :

http://img135.exs.cx/img135/2014/fsdf8hk.jpg



http://img135.exs.cx/img135/5161/whatimean0em.jpg

you will achieve this : NOTE THE DIFFERENCE NOW ?

cause with booleans , you get an insanely triangle count, and with alpha maps you get none and a better result , see some more xamples below


BUT WHAT THE HELL IS ALPHA MAPS ????

you see the image ? you see the white ? the white ares are the SOLID colors , the black are the TRANSPARENT colors , wich means , that when you use an alpha map in a model all the black areas in the uvw`s will turn transparent, while the white ones will be solid , if it is grey , it will be like semi-transparent, very usefull to make glass like objects :)

it is used on : - making hair
- making sometimes ropes
- clothes
- sprites
everithing...

heres another crappy example :

when u apply this environment map ( a photo i resized and cropped ) to a sphere and an alpha map of some highly contrasted cloud in photoshop , you can achieve a somekind of foggy effect on the texture, cause it tends to smooth out before beeing totaly transparent

http://img135.exs.cx/img135/881/helptwo0xs.gif


http://img135.exs.cx/img135/2587/alphadifuse8bo.jpg

this will make the following result if you have a 100% iluminated material

NOTE : i putted the material in 2sided for us to be able to see thru holes

http://img135.exs.cx/img135/9552/alphamapping5ei.jpg


continues in next post

SniperMaster
27-12-2004, 07:27 PM
Well, alpha maps aren't supported in EVERY engine. And most games don't render backfaces (what 2 sided does).

Just so people know exactly what alpha maps are:
They define what part of the model is rendered. Any area that is black is not rendered by the game engine, and areas that are white are.

coin
27-12-2004, 08:24 PM
my software rendered the same alpha map u have here but the holes were visable and the structure was not?

Johny
27-12-2004, 08:36 PM
well, quake 2 and quake 3 support 2 sided polies , and i think that with the right shader we can make almost every engine to do the same :)

LittleFish
28-12-2004, 06:30 AM
If the engine has low poly trees or plant life of any kind, it does support alpha maps, and you have been staring at them (also in broken windows, chain link fence or soccer goal net, etc.). The compatibility of an alpha map in an engine has not an issue for at least several years. This is simply an issue of the number of polygons saved by using an alpha map to show holes instead of booleans which make the mesh messy (in triangulation and thus smoothing) and drastically increase your poly count.

The point of this article seems to be, "Try using an alpha map instead of booleans, and see if the result isn't suitable graphically, while also saving you loads of polys" (and a lot of texturing of the insides of the holes).

edit: coin -- what software are you using? (quick help: under "output", select "invert" - may not help if not in Max))

Venom908
28-12-2004, 07:14 AM
thanks


brought my m82 down 500 tris :D

Ceccotti
28-12-2004, 08:28 AM
That saved you alot didnt it:D

coin
28-12-2004, 08:39 AM
well i dont know if starwars inverts or something but my softimage xsi renders the black part and white is tranparent,i think its the other way in 3ds max right?cause a .3ds model with alpha map made by someelelse. and it seems so.

IceWolve
30-12-2004, 06:03 PM
The way you did the holes in that cylinder is realy wastefull. Also, alpha maps can not make thick holes like actualy modeling the holes can. And like the other guy said, some engines dont support alpha maps or 2 sided polygons. So it all realy depends on the effect you want, you poly budget, and how its going to be looked at.