Alpha

Post » Tue May 17, 2011 3:27 pm

I've lost my notes on alpha settings and wonder if someone could please help

When i add the alpha property to a mesh it automatically sets the flags to 237 - I know Nioliv used 4333 - however I think there are some other settings that prevent alpha overlap happening

What I mean by overlapping is when i have 2 meshes such as clothes covering a body part one has an alpha and the other doesn't sometimes the area disappears depending on how close i am standing to the NPC - someone once told me a better flag number to avoid this or reduce the problem
User avatar
Curveballs On Phoenix
 
Posts: 3365
Joined: Sun Jul 01, 2007 4:43 am

Post » Tue May 17, 2011 7:30 am

For this, best way to experiment/learn so far to me is NiAlphaProperty dialog box in NIFSkope, you can see the meaning of various flag bits (enable blending, source blend mode, destination blend mode, enable testing, alpha test function, alpha test threshold, no sorter)

For instance, hair textures may profit from alpha test so hair does not disappear when submerged, different trees foliage can benefit from different settings, not easy to find best compromise but easier than figuring binary values.
Also, it is fast from Nifskope to open a similar mesh and examine its NiAlphaProperty for inspiration/comparison (especially if you use View\Block List\Show Blocks In List to find NiAlphaProperty quickly)

[EDIT]block list view note added
User avatar
Kevin S
 
Posts: 3457
Joined: Sat Aug 11, 2007 12:50 pm

Post » Tue May 17, 2011 8:14 am

Actually I would be interested in this as well if there is a way to stop things from going invis.
User avatar
David John Hunter
 
Posts: 3376
Joined: Sun May 13, 2007 8:24 am

Post » Tue May 17, 2011 3:04 pm

Yes, it is quite disconcerting when my beautifully clad companion becomes naked and bald underwater.
User avatar
Chica Cheve
 
Posts: 3411
Joined: Sun Aug 27, 2006 10:42 pm

Post » Tue May 17, 2011 12:22 am

I found an older post by Dirnae who shows how to change the alpha settings - am going to give this a go and see if it helps

Posted 30 March 2010 - 07:25 AM
It's how the alpha's overlap that cause the one wiremesh not to be visible when looking at it through the other.
Right click on the NiAlphaProperty and try out these settings: http://i647.photobuc.../Untitled-2.png
I suggest tweaking the 'Alpha Test Threshold' value to whatever looks best.

Using settings similar to these is a well known method of stopping alphas from overlapping wierdly, but it doesn't seem to work well with alphas which use alpha gradients, however for what you want this shouldn't matter.

I suggest learning Blender if you have the time, and don't have access to a later version of 3ds max, as max 4 and 5 are only really good for particles, and if you're not interested in these, Blender with it's newer functions, easier methods, and vast array of tutorials should serve you better.

User avatar
Alexandra Ryan
 
Posts: 3438
Joined: Mon Jul 31, 2006 9:01 am

Post » Tue May 17, 2011 11:34 am

I found an older post by Dirnae who shows how to change the alpha settings - am going to give this a go and see if it helps
I'm using a 13036 value, which right-clicking NiAlphaProperty\Flags in nifskope translates to
Enable blending: off
Enable testing: on
Alpha test function: greater
Alpha test threshold: 128
No sorter: on
Basically I have been able to to avoid hair texture vanishing in water only discarding the blending (shades of transparency) and using testing (transparent yes/no, no shades), then play and see with the threshold value, it is tolerable compromise with most hair but maybe a problem with many clothes.
User avatar
KiiSsez jdgaf Benzler
 
Posts: 3546
Joined: Fri Mar 16, 2007 7:10 am

Post » Tue May 17, 2011 4:22 am

So all this "enable testing" and "no sorter" and "src alpha," what does it mean, anyway?
User avatar
Shelby Huffman
 
Posts: 3454
Joined: Wed Aug 08, 2007 11:06 am

Post » Tue May 17, 2011 9:29 am

I use 4845 with a threshold of 192 (for clothing that is; it seems to
work the best and cooperates well with fog levels vs enchanted clothing).
It overlaps fine, too, if the article below has the same settings :) .
User avatar
teeny
 
Posts: 3423
Joined: Sun Feb 25, 2007 1:51 am

Post » Mon May 16, 2011 11:21 pm

I'm using a 13036 value, which right-clicking NiAlphaProperty\Flags in nifskope translates to
Enable blending: off
Enable testing: on
Alpha test function: greater
Alpha test threshold: 128
No sorter: on
Basically I have been able to to avoid hair texture vanishing in water only discarding the blending (shades of transparency) and using testing (transparent yes/no, no shades), then play and see with the threshold value, it is tolerable compromise with most hair but maybe a problem with many clothes.



No blending at all ? So it just looks for the src alpha - that would then make a bigger difference on whether you use a Dxt1, 3 or 5 wouldn't it?

I've been watching how the blends work in Nifskope and was trying all the different combinations of src colour inverse src colour and so on but have not tried turning blend off - with hair i was getting some radical results and was finding hair set to always produced the better looking result in nifskope - i still need to try it out in game

Westly - yes I to have discovered the need for both articles to be at the same alpha settings though am experimenting with alpha arms at different settings to the body to see if it makes any difference at all

Nothing like the trials of error I guess
User avatar
N3T4
 
Posts: 3428
Joined: Wed Aug 08, 2007 8:36 pm


Return to III - Morrowind