Scripting API

Scripting API

ImportedMesh

Record in Abyss.Core, from Abyss.Core.

One mesh of an imported model, as its file's tables describe it.

public record ImportedMesh

Constructors

ImportedMesh

public ImportedMesh(string Label, string Name, string Topology, uint Vertices, uint Indices, uint IndexBytes, IReadOnlyList<string> Streams, ulong Bytes, Vector3 Min, Vector3 Max)

One mesh of an imported model, as its file's tables describe it.

Parameters

  • Label: Its label in the model, Mesh0/Primitive0, as a scene names it after the model's path.
  • Name: The name the file gives the mesh it is part of, or nothing.
  • Topology: What its vertices make, in words: triangles, triangle strip, lines, line strip or points.
  • Vertices: How many vertices it has.
  • Indices: How many indices it has.
  • IndexBytes: How many bytes an index takes: 2, 4, or none for a mesh with no indices.
  • Streams: What each of its vertices holds, in words: position, normal, UV0, tangent and so on.
  • Bytes: How many bytes its vertices and indices take.
  • Min: The corner of its bounding box with the smallest coordinates.
  • Max: The corner with the largest.

Properties

Label

public string Label { get; init; }

Its label in the model, Mesh0/Primitive0, as a scene names it after the model's path.

Name

public string Name { get; init; }

The name the file gives the mesh it is part of, or nothing.

Topology

public string Topology { get; init; }

What its vertices make, in words: triangles, triangle strip, lines, line strip or points.

Vertices

public uint Vertices { get; init; }

How many vertices it has.

Indices

public uint Indices { get; init; }

How many indices it has.

IndexBytes

public uint IndexBytes { get; init; }

How many bytes an index takes: 2, 4, or none for a mesh with no indices.

Streams

public IReadOnlyList<string> Streams { get; init; }

What each of its vertices holds, in words: position, normal, UV0, tangent and so on.

Bytes

public ulong Bytes { get; init; }

How many bytes its vertices and indices take.

Min

public Vector3 Min { get; init; }

The corner of its bounding box with the smallest coordinates.

Max

public Vector3 Max { get; init; }

The corner with the largest.

Triangles

public uint Triangles { get; }

How many triangles it draws: none for lines or points.

Size

public Vector3 Size { get; }

The size of its bounding box.