Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

Saiz

transparent glass cockpit

This topic is 6193 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi, I have problems with my Voodoo 3 to get a transparent glass cockpit making use of the typical senteces, m_d3dDevice.SetRenderState D3DRS_ALPHABLENDENABLE, 1 m_d3dDevice.SetRenderState D3DRS_SRCBLEND, D3DBLEND_SRCCOLOR m_d3dDevice.SetRenderState D3DRS_DESTBLEND, D3DBLEND_INVSRCCOLOR Any suggestion? Thank you, Saiz

Share this post


Link to post
Share on other sites
Advertisement
I am not sure, but would it not be wiser to use D3DBLEND_SRCALPHA and D3DBLEND_INVSRCALPHA. The alpha channel is simpler to control the transparency, and will probably work on more cards.

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
Thanks Chock,
But the problem (what I know) is that this solution adds transparency, but doesn''t absorb the background color. When you see through that kind of glass the background is clearer.
Saiz

Share this post


Link to post
Share on other sites
With alpha blending you need to presort your objects and then draw them back to front!

I don''t know if this would help but I had a similar problem with a particle system I was writing that alpha blended all the particles. I was drawing them in the wrong order.




D.V.

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!