There is a problem with specifying the texture coordinates.

From the documentation and examples i understand that the preferred way to specify texture coordinates for genmesh factories is in the "v" tags, for example:

<v x="-0.338703" y="-0.637001" z="6.718997" u="0.562855" v="0.616343" nx="-0.050111" ny="-0.094241" nz="0.994263"/>

texture coordinates however should be "tied" to triangles, and not to vertices.

In an example like in file "castle\factories\genCube" this is solved by repeating the vertex definition for each triangle:

<v x="-0.338703" y="-0.637001" z="6.718997" u="0.562855" v="0.616343" nx="-0.050111" ny="-0.094241" nz="0.994263"/>

<v x="-0.338703" y="-0.637001" z="6.734554" u="0.562855" v="-1.302350" nx="0.000000" ny="-0.816492" nz="-0.577349"/>

<v x="-0.323146" y="-0.637001" z="6.718997" u="0.552967" v="-1.302350" nx="0.000000" ny="0.000000" nz="-1.000000"/>

<t v1="2" v2="1" v3="0"/>

<v x="-0.338703" y="-0.637001" z="6.734554" u="0.552967" v="-1.302350" nx="0.000000" ny="-0.816492" nz="-0.577349"/>

<v x="-0.338703" y="-0.637001" z="6.718997" u="0.574173" v="-1.302350" nx="-0.050111" ny="-0.094241" nz="0.994263"/>

<v x="-0.354259" y="-0.637001" z="6.718997" u="0.552967" v="0.616343" nx="1.000000" ny="0.000000" nz="0.000000"/>

<t v1="5" v2="4" v3="3"/>

Although this is inefficient it works.

For the submesh however it is a problem, because you can only specify vertex indices (for the triangles). I don't know how to specify "triangle specific" texture

coordinates.

Is there a solution for this?