I am trying to build a tool to export and import binary models from an old DX9 game. The models are packed in a single file and I have managed to extract the relevant parts in hexadecimal.
By analyzing the Vertex buffer, I have concluded that it was using the following format. Basically the stride is 24 bytes.
struct CUSTOMVERTEX
{
CUSTOMVERTEX(FLOAT fx, FLOAT fy, FLOAT fz, DWORD dwcolor, FLOAT fu, FLOAT fv) :
X(fx), Y(fy), Z(fz), COLOR(dwcolor), U(fu), V(fv) {}
FLOAT X, Y, Z;
DWORD COLOR;
FLOAT U, V;
};
#define CUSTOMFVF (D3DFVF_XYZ | D3DFVF_DIFFUSE | D3DFVF_TEX1)I …