Vixen
dd8b0a81
csharp
public record class PolygonMesh

One mesh on its way to a file, still made of faces rather than of triangles.

Read the guide page for this →

Remarks

docs/plan/41 § Part 4 asks for quads and MeshData cannot carry one. That type is what a vertex buffer looks like — one vertex per corner, three corners per triangle — so a retopology that went through it arrived at the file already triangulated and already exploded, with every quad an island of four vertices joined to nothing. Measured on a 5 766-quad result: 11 532 triangles, 23 064 positions, and the only edges with two faces were the diagonals inside each split quad.

⚠ This is the writer's input and not a rendering structure, and the difference is the whole point. EditMesh shares a position between the faces that meet there and keeps a face's corner loop at whatever length it is, which is what OBJ's f a b c d wants. Going to MeshData is a one-way trip and the writers that must take it — glTF and GLB, which are triangles-only by specification — take it at the point of writing, where they can say so.

Fields and properties (3)

  • public required EditMesh Mesh

    The geometry, with its faces at whatever number of sides they have.

  • public string Name

    What to call it in the file.

  • public IReadOnlyList<Vector2> TexCoords

    One texture coordinate per corner — CornerCount of them — or empty for a mesh that has none.

Used by (2)

  • GeometryRunnerVixen.Cli
  • ModelWriterVixen.Editor.Assets