Creates a VoxelModelWriter instance.
An array of RGB color triplets for the voxel model palette.
OptionalsectionSize: number = 64Size of the sparse models as chunks.
Set a voxel with a color palette index. Z is gravity direction.
X coordinate of voxel.
Y coordinate of voxel.
Z coordinate of voxel.
Color palette index.
Generate a MagicaVoxel formatted buffer.
OptionalreleaseInternalData: boolean = falseRelease internal data used for representing model.
A buffer containing the voxel model in MagicaVoxel format.
StaticwriteWrites an ASCII-formatted string to the buffer.
The buffer used for writing the string to.
The string to write with.
StaticwriteWrites a key-value dictionary structure to the buffer.
The buffer to write the dictionary with.
Optionalobject: {} = {}The object used as a key-value dictionary.
Class for writing large voxel models in MagicaVoxel format.
Example