An exporter for PLY.
PLY (Polygon or Stanford Triangle Format) is a file format for efficient delivery and loading of simple, static 3D content in a dense format. Both binary and ascii formats are supported. PLY can store vertex positions, colors, normals and uv coordinates. No textures or texture references are saved.
const exporter = new PLYExporter();
const data = exporter.parse( scene, options );
PLYExporter is an addon, and must be imported explicitly, see Installation#Addons.
import { PLYExporter } from 'three/addons/exporters/PLYExporter.js';
Parses the given 3D object and generates the PLY output.
If the 3D object is composed of multiple children and geometry, they are merged into a single mesh in the file.
object
The 3D object to export.
onDone
A callback function that is executed when the export has finished.
options
The export options.
Returns: The exported PLY.
onDone callback of PLYExporter.
result
The generated PLY ascii or binary.
Export options of PLYExporter.
binary
boolean
Whether to export in binary format or ASCII.
Default is false.
excludeAttributes
Array.
Which properties to explicitly exclude from the exported PLY file. Valid values are 'color', 'normal', 'uv', and 'index'. If triangle indices are excluded, then a point cloud is exported.
littleEndian
boolean
Whether the binary export uses little or big endian.
Default is false.