Direct3D中 lpd3dDevice 的问题

lpd3dDevice->CreateVertexBuffer

里面定义的顶点为神马必须是浮点类型

整型为什么没有作用啊??

typedef struct _customvertex
{
float x;
float y;
float z;
float rhw;
DWORD color;
}CUSTOMVER; //自定义一个顶点类型

CUSTOMVER CustomVertex[6] = {0};

int i;
for(i=0;i<6;i++)
{
    CustomVertex[i].x = rand() % 800;//(800.0*rand()/(RAND_MAX+1.0));
    CustomVertex[i].y = rand() % 600;//(600.0*rand()/(RAND_MAX+1.0));
    CustomVertex[i].z = 0;
    CustomVertex[i].rhw = 1;
    CustomVertex[i].color = D3DCOLOR_XRGB(rand() % 256, rand() % 256, rand() % 256);
}

如果将结构体中浮点型改为int型就不起作用了

为什么??