GltfExporter

Overview

GltfExporter converts an in-memory Scene graph into glTF (.gltf/.glb) format and writes the result to a file path or output stream. It is invoked automatically by Scene.save() when the target file extension is .gltf or when a GltfSaveOptions instance is passed explicitly to control output. Pass a GltfSaveOptions object to govern serialisation details such as coordinate-system handedness, vertex precision, and optional format-specific extensions during the export operation.

Description

GltfExporter is a class in the Aspose.3D FOSS library for TypeScript that exposes 2 methods and 13 properties for programmatic use. It extends Exporter, inheriting shared functionality from its parent type.

Core capabilities include: : number[]; : number[]; : number. These operations enable developers to integrate gltfexporter functionality directly into TypeScript applications.

The class also provides the min property (holds the minimum coordinate values of the exported scene’s bounding box), the max property (provides the maximum bounds of the exported data (duplicate entry)), the x property (stores the x component of an internal vector used during export).

Instances are created through a single constructor that initializes the object with default values.

Properties

NameTypeAccessDescription
min: number[]ReadHolds the minimum coordinate values of the exported scene’s bounding box
max: number[]ReadProvides the maximum bounds of the exported data (duplicate entry)
x: numberReadStores the X component of an internal vector used during export
y: numberReadStores the Y component of a secondary vector used during export
z: numberRead
w: numberRead
x: numberReadStores the X component of an internal vector used during export
y: numberReadStores the Y component of a secondary vector used during export
z: numberRead
x: numberReadStores the X component of an internal vector used during export
y: numberReadStores the Y component of a secondary vector used during export
min: number[]ReadHolds the minimum coordinate values of the exported scene’s bounding box
max: number[]ReadProvides the maximum bounds of the exported data (duplicate entry)

Methods

SignatureDescription
constructor()
supportsFormat(fileFormat: FileFormat)booleanReturns true if the exporter can handle the specified FileFormat
export(scene: Scene, stream: any, options: SaveOptions)Writes the given Scene to the provided stream using the supplied SaveOptions

See Also