• Advertisement
Sign in to follow this  

alpha channel

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

im hoping someone can shed some light on this becuase its makes no sense to me. im creating a game in C# and have just successfully made a fade in / fade out effect using directX sprite calls and changing the alpha value. it works perfectly, but becuase I have an animation (which the frames are stored in a tileset bitmap) I have to make two calls, one to Sprite.Draw and one to Sprite.Draw2D. I use the sprite.Draw function b/c it lets me specify the rectangle to draw within the tileset. Now heres the problem..... The rates of the fading are not the same. The calls are back to back, so the m_Alpha value doesnt change, but the animated rectangle fades in slower than the non animated section. for example, I do a call to BGSprite.Draw2D(m_Texture, new Point(0, 0), 0f, new Point(0, 0), Color.FromArgb(m_Alpha, Color.White)); BGSprite.Draw(m_Texture, m_Options[OptionIndex].GetCurrentCoordinates(), Vector3.Empty, m_OptionCoords, Color.FromArgb(m_Alpha, Color.White)); i hope you understand my problem. i have no idea why its doing what it does. Thanks!

Share this post


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

  • Advertisement