original width of a DirectX texture

Started by
2 comments, last by hughiecoles 13 years, 4 months ago
Is there any way to find the original width of a DirectX texture image? For instance, if an image is 541 pixels wide but gets scaled to 1024,

I want to get the 541.
Advertisement
How did the image get scaled? Generally if you scale it, you know the size beforehand.

Note that scaling at runtime is different than resizing at load time, if that's what you really mean.
I think what he's saying is that when he applies the sprite as a texture to a quad it gets scaled because it is close to the camera and the projection gets larger then the original resolution. Think changing the camera to Orthographic projection will do the trick. Don't know how to actually do it though.

Video Game Programmer.
5 years in industry.

actually it sounds like he's saying if he loads an image, but puts in a different texture size (automatically scaling it), can he get the original dimensions back, in which case no. If I'm wrong about your question, I apologize.
--------------------------------------Not All Martyrs See Divinity, But At Least You Tried

This topic is closed to new replies.

Advertisement