Data types

更新时间:
复制 MD 格式

Mesh SQL provides four custom data types for storing and querying 3D mesh data: texture, material, meshgeom, and sfmesh.

TypeCategoryDescription
textureTexture typeStores width, height, compression method, and binary texture data. Multiple objects can share one texture.
materialMaterial typeDescribes the visual attributes of an sfmesh object's surface. Can be associated with texture information.
meshgeomGeometric typeRecords coordinates and surface construction descriptions. Use for white films that require no textures or materials.
sfmeshCollection typeA collection of data types that contain information about geometries, materials, textures, and texture coordinates.

Type relationships

sfmesh is a collection type that contains the other three types:

sfmesh
├── meshgeom   (geometry: coordinates and surface construction)
├── material   (surface visual attributes, optionally linked to texture)
└── texture    (width, height, compression method, binary texture data)

Multiple objects can share one texture. A material can be associated with texture information.

When to use meshgeom vs sfmesh

  • Use meshgeom for white films: geometry-only models that require no textures or materials.

  • Use sfmesh when you need a complete 3D object that combines geometry with surface appearance data.

Type reference

texture

The texture type stores all data needed to apply a texture to a 3D surface:

  • Width and height: Dimensions of the texture image.

  • Compression method: The algorithm used to compress the texture data.

  • Binary texture data: The raw texture content in binary form.

material

The material type describes the visual attributes of an sfmesh object's surface. A material can be associated with a texture to apply image-based surface detail.

meshgeom

The meshgeom type is the geometric foundation of a 3D mesh. It records:

  • Coordinates: Positions used to record the geometry.

  • Surface construction descriptions: How vertices connect to form the mesh surface.

Use meshgeom when working with white films — untextured geometry models that do not need material or texture data.

sfmesh

sfmesh is a collection type that bundles all the information needed for a described 3D object:

  • Geometry (meshgeom)

  • Surface appearance (material)

  • Image data (texture)

  • Texture coordinates