Sign in to follow this  

Texture deformations

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

I loaded a texture and create a sprite, my texture is 800x600, i set it position 0 0 and center 0 0, but the texture looking like it was increased 2-fold...it position is not 0..its like 50 50 and i can see only 1/4 of texture...why it was increased?

Share this post


Link to post
Share on other sites
Are you using ID3DXSprite interface to display that texture? if yes then the coordinates of the sprite should be specified in RECT format, for example:

[code]RECT oClientRect[] =
{
{10, 10, 120, 30}, // For FPS data
{10, 30, 300, 50}, // For timer data
};[/code]

Refer to array 1: left: 10 top:10 right: 120 bottom: 30

Share this post


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