of the output atlas (default is 4096)
of the output atlas (default is 4096)
between glyphs/images (default is 0)
The Bin array added to the packer
of the output atlas (default is 4096)
between glyphs/images (default is 0)
of the output atlas (default is 4096)
Return current functioning bin index, perior to this wont accept any new elements
Returns dirty status of all child bins
Return all rectangles in this packer
Add a bin/rectangle object with data to packer
of the input bin/rectangle
of the input bin/rectangle
custom data object
Add a bin/rectangle object extends IRectangle to packer
the rect object add to the packer bin
Add an Array of bins/rectangles to the packer.
Javascript
: Any object has property: { width, height, ... } is accepted.
Typescript
: object shall extends MaxrectsPacker.IRectangle
.
note: object has hash
property will have more stable packing result
Array of bin/rectangles
Load bins to the packer, overwrite exist bins
MaxRectsBin objects
Stop adding new element to the current bin and return a new bin.
note: After calling next()
all elements will no longer added to previous bins.
Repack all elements inside bins
Reset entire packer to initial states, keep settings
Output current bins to save
Options for MaxRect Packer
Generated using TypeDoc
Creates an instance of MaxRectsPacker.
MaxRectsPacker