How to create Alpha mapping ?

Topics relating to Modeling with Reality Factory.
User avatar
anhdung86
Posts: 45
Joined: Mon Jun 30, 2008 9:47 am
Location: hanoi/vietnam
Contact:

How to create Alpha mapping ?

Post by anhdung86 » Wed Aug 13, 2008 11:44 am

Ok, my game must has so many trees and i want to create lowest poly tree (for good frame rate), but i don't know how to create alpha mapping for leaf in trees, like that:

Image

Anybody please help me about that, thankz verymuch :(

Danimita92
Posts: 335
Joined: Sat Feb 09, 2008 5:47 pm
Location: Lanzarote/Canary Islands/Spain

Re: How to create Alpha mapping ?

Post by Danimita92 » Wed Aug 13, 2008 12:32 pm

You need the texture of the leaves, then make a targa (.tga) image out of it. This image is gray, black and white. Black will be fully transparent, white will stay, and gray will be a little transparent.
Use the original texture on the tree's actor, and then use the tool "tga2gebmp2", load the tree's actor, and replace the leaf texture with the targa. Save, and there you are. An alpha texture

User avatar
anhdung86
Posts: 45
Joined: Mon Jun 30, 2008 9:47 am
Location: hanoi/vietnam
Contact:

Re: How to create Alpha mapping ?

Post by anhdung86 » Wed Aug 13, 2008 12:36 pm

Thank Danimita, i will try it :D

User avatar
anhdung86
Posts: 45
Joined: Mon Jun 30, 2008 9:47 am
Location: hanoi/vietnam
Contact:

Re: How to create Alpha mapping ?

Post by anhdung86 » Wed Aug 13, 2008 8:43 pm

Now, I have a problem with this:
-First i create 2 texture, one for tree body and one for leaf (.bmp):
ImageImage

-Then i create alpha texture for leaf (.tga):
Image

-After convert my tree to .act file i use "tga2gebmp2" and replace the leaf texture with the targa. But when i view my tree with Equity, those leaf didn't transparent:
Image

This is my tree actor and .tga file:
tga: http://www.mediafire.com/?adlaazma0ao
actor: http://www.mediafire.com/?ys3x3cd1men

Anybody know why? :(

User avatar
bernie
RF Moderator
Posts: 1249
Joined: Tue Nov 15, 2005 10:07 am
Location: Ireland

Re: How to create Alpha mapping ?

Post by bernie » Wed Aug 13, 2008 8:58 pm

You don't need to use "tga2gebmp2".
just load the actor into equity and change the texture there for your tga.
Which version of Equity are you using?

User avatar
anhdung86
Posts: 45
Joined: Mon Jun 30, 2008 9:47 am
Location: hanoi/vietnam
Contact:

Re: How to create Alpha mapping ?

Post by anhdung86 » Wed Aug 13, 2008 9:11 pm

You don't need to use "tga2gebmp2".
just load the actor into equity and change the texture there for your tga.
I used Equity then the result didn't change.
Which version of Equity are you using?
I used Equily 4.2.1

User avatar
bernie
RF Moderator
Posts: 1249
Joined: Tue Nov 15, 2005 10:07 am
Location: Ireland

Re: How to create Alpha mapping ?

Post by bernie » Wed Aug 13, 2008 9:15 pm

The version of equity you are using is out of date.
download the latest version from my filefront account http://hosted.filefront.com/bernieRF/
version 4.2.5 supports tga and will show transparencies correctly in the viewer.

User avatar
Juutis
Posts: 1511
Joined: Thu Jan 12, 2006 12:46 pm
Location: Finland

Re: How to create Alpha mapping ?

Post by Juutis » Wed Aug 13, 2008 9:22 pm

You need to combine the texture and the alpha map to a .tga file with the AlphaCreate program (in your tools folder). Right now your alpha map is a .tga.

So, save your alpha map as .bmp -> open AlphaCreate -> enter the bitmap and the alpha map and hit 'Create'. And then you can use Equity to replace the texture.
Pain is only psychological.

User avatar
bernie
RF Moderator
Posts: 1249
Joined: Tue Nov 15, 2005 10:07 am
Location: Ireland

Re: How to create Alpha mapping ?

Post by bernie » Wed Aug 13, 2008 9:29 pm

You need to combine the texture and the alpha map to a .tga file with the AlphaCreate program (in your tools folder). Right now your alpha map is a .tga.
Yes true, I didn't spot that

User avatar
anhdung86
Posts: 45
Joined: Mon Jun 30, 2008 9:47 am
Location: hanoi/vietnam
Contact:

Re: How to create Alpha mapping ?

Post by anhdung86 » Wed Aug 13, 2008 9:30 pm

@Juutis & bernie: I made it !!! :D Thank you very much :D

User avatar
anhdung86
Posts: 45
Joined: Mon Jun 30, 2008 9:47 am
Location: hanoi/vietnam
Contact:

Re: How to create Alpha mapping ?

Post by anhdung86 » Fri Aug 15, 2008 8:47 pm

I have a problem with those leaf, when i put it in my level, they look very dark:

Image

I think it's dark because i put a dynamic light above, so the surface which is not being light will dark, so how can i made it not being effect by light? (i try StaticMess entity but my tree look very bad). Any body help me please! :(

User avatar
steven8
Posts: 1487
Joined: Wed Aug 24, 2005 9:08 am
Location: Barberton, OH

Re: How to create Alpha mapping ?

Post by steven8 » Sat Aug 16, 2008 4:24 am

Make sure your fillcolor is 255,255,255 on the entity for the tree.
Steve Dilworth - Resisting change since 1965!

User avatar
anhdung86
Posts: 45
Joined: Mon Jun 30, 2008 9:47 am
Location: hanoi/vietnam
Contact:

Re: How to create Alpha mapping ?

Post by anhdung86 » Sat Aug 16, 2008 9:08 am

I used fillcolor 255,255,255 but it didn't change :(

This is my tree actor:
http://www.mediafire.com/?ldlaabn1jpw

User avatar
steven8
Posts: 1487
Joined: Wed Aug 24, 2005 9:08 am
Location: Barberton, OH

Re: How to create Alpha mapping ?

Post by steven8 » Sat Aug 16, 2008 9:26 am

Have you tried removing (or just moving) the dynamic light and trying say, a sunlight entity to see if there is a difference?
Steve Dilworth - Resisting change since 1965!

User avatar
anhdung86
Posts: 45
Joined: Mon Jun 30, 2008 9:47 am
Location: hanoi/vietnam
Contact:

Re: How to create Alpha mapping ?

Post by anhdung86 » Sat Aug 16, 2008 10:05 am

I tried both Sunlight and Sun entity, but the result didn't change, i don't know why :(

Post Reply