http://stashbox.org/957223/Untitled.png : A image with the problem more noticable.
D3D9 co-ordinates are out of whack. On XP its perfect. Not sure what the issue is.
The relevant code is:
Code: Select all
typedef struct
{
FLOAT x, y, z;
D3DCOLOR diffuse;
FLOAT u,v;
} VERTEX;
#define VertexFVF (D3DFVF_XYZ | D3DFVF_DIFFUSE | D3DFVF_TEX1)
static VERTEX srcvtx[4]=
{
{-1.0f, 1.0f,1.0f, 0xffff0000, 0 ,0},
{ 1.0f, 1.0f,1.0f, 0xffff00ff, 0 ,0},
{ 1.0f,-1.0f,1.0f, 0xffffff00, 0 ,0},
{-1.0f,-1.0f,1.0f, 0xff00ff00, 0 ,0},
};
Code: Select all
srcvtx[1].u = width / (float)texwidth;
srcvtx[2].u = width / (float)texwidth;
srcvtx[2].v = height / (float)texheight;
srcvtx[3].v = height / (float)texheight;
hr = d3ddev->DrawPrimitiveUP(D3DPT_TRIANGLEFAN, 2, srcvtx, sizeof(VERTEX));
So I am quite stumped. Any help would be appreciated.