   Stretching a texture to windows size
  Hey im pretty new to DirectX and need help with a thing.I'm working a 2D sidescrolling game, like any Mario-like game. I have a background texture that is 512x512 in dimensions. The screen is 800x600 and i want the texture to stretch out over the whole screen.I came up with this:   D3DSURFACE_DESC texInfo;mBkgdTex->GetLevelDesc(0, &texInfo);float sx, sy;sx = 800/320;sy = 600/320;D3DXMATRIX T, S;D3DXMatrixTranslation(&T, 1, 1, 1);D3DXMatrixScaling(&S, sx, sy, 0.0f);HR(mSprite->SetTransform(&(S*T)));I get how many of the texture in x it would take to fill the screen in x etc and the same with y coordinates. But it ends up with the texture far from being stretched out to fill up the whole screen. Am i doing something wrong, please tell me!Oh and btw, when i run my program it seems that the texture isnt 512x512 on the screen. It's way smaller than the picture when i look at it in Photoshop.Can somone please straight this out for me :)Greetings,simpler[Edited by - simpler on November 17, 2010 4:05:23 PM]
  bump   