Jump to content

  • Log In with Google      Sign In   
  • Create Account

Interested in a FREE copy of HTML5 game maker Construct 2?

We'll be giving away three Personal Edition licences in next Tuesday's GDNet Direct email newsletter!

Sign up from the right-hand sidebar on our homepage and read Tuesday's newsletter for details!


We're also offering banner ads on our site from just $5! 1. Details HERE. 2. GDNet+ Subscriptions HERE. 3. Ad upload HERE.


D3DTLVERTEX alpha verticies


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
1 reply to this topic

#1 Ro   Members   -  Reputation: 122

Like
Likes
Like

Posted 26 January 2000 - 08:48 PM

I''ve been struggling with this for almost forever now, and can''t seem to figure out how to dynamically make my bitmap translucent. I''m using D3DTLVERTEX and was attempting to just change the alpha values for the verticies, but that didn''t affect the translucency rendering. I also tried setting different values for the current device material, and different rendering states. Here is my rendering state if it helps any: d3d_device->SetRenderState( D3DRENDERSTATE_COLORKEYENABLE, TRUE ); d3d_device->SetRenderState( D3DRENDERSTATE_ALPHABLENDENABLE, TRUE ); d3d_device->SetRenderState(D3DRENDERSTATE_SRCBLEND, D3DBLEND_SRCALPHA ); d3d_device->SetRenderState(D3DRENDERSTATE_DESTBLEND, D3DBLEND_INVSRCALPHA ); d3d_device->SetRenderState( D3DRENDERSTATE_AMBIENT, 0x00000000 ); d3d_device->SetRenderState( D3DRENDERSTATE_DITHERENABLE, TRUE ); d3d_device->SetRenderState( D3DRENDERSTATE_SPECULARENABLE, FALSE ); d3d_device->SetTextureStageState( 0, D3DTSS_COLORARG1, D3DTA_TEXTURE ); d3d_device->SetTextureStageState( 0, D3DTSS_COLORARG2, D3DTA_DIFFUSE ); d3d_device->SetTextureStageState( 0, D3DTSS_COLOROP, D3DTOP_MODULATE ); d3d_device->SetTextureStageState( 0, D3DTSS_MINFILTER, D3DTFN_LINEAR ); d3d_device->SetTextureStageState( 0, D3DTSS_MAGFILTER, D3DTFG_LINEAR ); d3d_device->SetTextureStageState( 0, D3DTSS_ADDRESS, D3DTADDRESS_CLAMP );

Sponsor:

#2 Ro   Members   -  Reputation: 122

Like
Likes
Like

Posted 26 January 2000 - 09:56 PM

I found my mistake .... I forgot to set the alpha operations ... DOH!!!




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS