VBGamer |
|||||||||||||||||||||||||||||||||||||||||||||||||||||
Re: Loading textures and finding dimensions... Adam Hoult (2 replies, 0 views) (2001-Jan-2) Hey Mateo,
Ok, if you use CreateTextureFromFileEX to create your texture, you can simply pass 0 to both the width and the height, this will specify the sizes stored in the image file... Then to retrieve the size of the loaded texture, use Direct3DTexture8::GetLevelDesc, which will return a D3DSURFACE_DESC structure. This contains the information about the texture (including width / height).
HTH
--
Adam Hoult
Lead Programmer
Atypical Interactive
http://www.atypical-interactive.com
|