Jump to content
  • Advertisement
Sign in to follow this  
CastorX

D3DXSPRITE Problem

This topic is 4657 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

Hy! I'm trying to make my particle system's drawing function sprite based with ID3DXSprite, but the final image on the screen is terrible. What's the problem? here's the code: SpriteObject->Begin(D3DXSPRITE_OBJECTSPACE | D3DXSPRITE_BILLBOARD | D3DXSPRITE_ALPHABLEND); ... LOOP ... D3DXMatrixScaling(&Mat1,Particles.Scale,Particles.Scale,Particles.Scale); D3DXMatrixRotationZ(&Mat3,Particles.Rotation); D3DXMatrixTranslation(&Mat2, Particles.Pos.x,Particles.Pos.y,Particles.Pos.z); FINAL = Mat1 * Mat3 * Mat2; SpriteObject->SetWorldViewRH(&FINAL,NULL); SpriteObject->Draw(Textures[Particles.TextureID],NULL,NULL,NULL,Particles.Color); ... LOOPEND

Share this post


Link to post
Share on other sites
Advertisement
Well other than the background being buggy.. I don't really know what to look for.. make sure that you clear the backbuffer each frame. Other than that I don't really know what to look for...

Share this post


Link to post
Share on other sites
What is buggy about it? Like the above poster, the particles look fine, but the background is a bit odd... Is the background not supposed to look like that..?

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • 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!