Skip to main content
gamedev.net
🔒 Locked

Object Transparancy

Started by dragon9 Mar 22, 2004 at 8:23 PM 1 replies 800+ views
Original Post
dragon9
dragon9
In DX9, how do I use SetRenderState with D3DRS_SRCBLEND and D3DRS_DESTBLEND to gradualy make an entire object fade to 100% transparent over time? What I want to do is each frame scale the minimum transparancy level from 0% to 100%. Is there a better way to do this? Thanks...
dragon9
dragon9
bump
aker_jus
aker_jus
For alpha blending, use SRC = SRCALPHA and DEST = INVSRCALPHA

For the object to fade, you can change the Alpha component of your material color, or change the vertex color''s Alpha component (if you are using vertex coloring instead of d3d lighting). You can also use Texture factor renderstate and a combination of
D3DTA_TEXTURE and D3DTA_TFACTOR for texture modulation and make Tfactor a color with some alpha < 255.


GraphicsWare|RenderTech
-----------------------
http://www.graphicsware.com

3D Graphics & Solutions
GraphicsWare|RenderTechhttp://www.graphicsware.com3D Graphics & Solutions

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.