saveMesh
import { saveMesh } from '@banou/opencv-wasm'Use after await initOpenCV(). See the initialization and named imports guide.
ARGUMENTSfilename, vertices, indices, normals
FUNCTIONsaveMesh
RETURN TYPEvoid
Saves a mesh to a specified file.
The function saves mesh to the specified file. File format is chosen based on the filename extension.
saveMesh(filename: EmbindString, vertices: Mat, indices: MatVector, normals: Mat, colors: Mat, texCoords: Mat): void;4 available overloads
saveMesh(filename: EmbindString, vertices: Mat, indices: MatVector): void;saveMesh(filename: EmbindString, vertices: Mat, indices: MatVector, normals: Mat): void;saveMesh(filename: EmbindString, vertices: Mat, indices: MatVector, normals: Mat, colors: Mat): void;saveMesh(filename: EmbindString, vertices: Mat, indices: MatVector, normals: Mat, colors: Mat, texCoords: Mat): void;filenameName of the file.
verticesvertex coordinates, each value contains 3 floats
indicesper-face list of vertices, each value is a vector of ints
normalsper-vertex normals, each value contains 3 floats
colorsper-vertex colors, each value contains 3 floats
texCoordsper-vertex texture coordinates, each value contains 2 or 3 floats
These signatures describe this package. Upstream documentation can mention optional backends that are absent from this build. Check runtime compatibility before choosing a backend or file format.