   Having trouble with texture alpha blending [solved]
  Okay, so I'm trying to make some textures on a primitive transparent when they're in the camera's way. Some other times I might like to tint them some RGB value; basically i need to be using alpha blending here, and I think I have to use texture alpha for this, correct?Anyways, I'm doing this beforehand:p_dx_Device->SetRenderState(D3DRS_TEXTUREFACTOR, 0x80FFFFFF);p_dx_Device->SetTextureStageState(0, D3DTSS_COLOROP, D3DTOP_MODULATE);p_dx_Device->SetTextureStageState(0, D3DTSS_COLORARG1, D3DTA_TEXTURE);p_dx_Device->SetTextureStageState(0, D3DTSS_COLORARG2, D3DTA_TFACTOR);p_dx_Device->SetTextureStageState(0, D3DTSS_ALPHAOP, D3DTOP_MODULATE);p_dx_Device->SetTextureStageState(0, D3DTSS_ALPHAARG1, D3DTA_TEXTURE); p_dx_Device->SetTextureStageState(0, D3DTSS_ALPHAARG2, D3DTA_TFACTOR);p_dx_Device->SetRenderState(D3DRS_ALPHABLENDENABLE, TRUE);p_dx_Device->SetRenderState(D3DRS_SRCBLEND, D3DBLEND_SRCALPHA);p_dx_Device->SetRenderState(D3DRS_DESTBLEND, D3DBLEND_INVSRCALPHA);(I'll admit right now that I don't have the greatest understanding of some of these things, so i make sure to use the get states beforehand, and reset all the states to avoid breaking things. )This is what I've gathered that I should be doing from various tutorials or code or posts, and it does work for RGB, but it doesn't work for transparency. Anything else i should be doing? I've seen mention of the Zbuffer, but I don't think I can disable the Z-buffer at this point.[Edited by - sqpat on August 8, 2008 11:45:09 AM]
  I got it! lights had to be disabled. :)   