Problems with transparencies/alpha channels in tree foliage

Me again – still having trouble with my tree model. Thanks to Snood_1990 for his help suggesting the “$nocull” “1” to fix my one sided faces; the texture is now showing on both sides. However, I’m still having trouble with my transparencies.

Quick recap the tree just a trunk with a series of rectangular overlapping faces with foliage textured on them. In game with they look like this:

http://i2.photobucket.com/albums/y31/john41/th_newmodeltester0008.jpg

It still needs some work but this is basically what I want it too look like. The foliage panels look too square and I was going to round them out and remove the black areas by adding an alpha channel and making all the black areas transparent. This is the result:

http://i2.photobucket.com/albums/y31/john41/th_newmodeltester0009.jpg http://i2.photobucket.com/albums/y31/john41/th_newmodeltester0011.jpg

As you can see the black areas are gone like I wanted but there is something seriously wrong with the tree’s foliage and I have no idea what it is. It’s also curious that its only happening to the leaves since the trunk appears unaffected. Here’s what the template of the texture looks like pre-alpha:

http://i2.photobucket.com/albums/y31/john41/th_Tree_gamma_old.jpg

This is what the vmt looks like:


 "vertexlitgeneric"
{
	"$basetexture" "models/BigTree1/Tree_gamma"
	"$nocull" 1
	"$translucent" 1
}

I’ve tried the suggested “alphatest” “1” but I saw no visible change in the transparencies.

Anyone have any ideas?

I had the same problem with PKt’s Vanilla Model.
What you need to add is “$halflambert” 1 and maybe “$alphatest” 1 and remove “$translucent” 1

“translucent” messes with depth sorting, and is slower than alpha testing.

You could also enable “alpha to coverage”, it’ll blur the edges of the texture and make it look less blocky (the “$AllowAlphaToCoverage” VMT parameter)

Thanks guys, that was indeed the problem here’s what they look like now:

http://i2.photobucket.com/albums/y31/john41/The%20Genesis%20Project%20-%20Sonic%20Adventure%20Past%20Levels/th_genesis_project_skybox_det0025.jpg http://i2.photobucket.com/albums/y31/john41/The%20Genesis%20Project%20-%20Sonic%20Adventure%20Past%20Levels/th_genesis_project_skybox_det0027.jpg

The edges are still a bit off, not sure what I can do about that apart from going in and adjusting it pixel by pixel.

I appreciate your help.