Use the texture index to get the texcoord size from the fvf, not the vertex index.
Attach a file by drag & drop or click to upload