Free texture packer module for gulp
Based on https://github.com/odrick/free-tex-packer
$ npm install gulp-free-tex-packer
let texturePacker = require('gulp-free-tex-packer');
gulp.task('pack', function() {
return gulp.src('src/**/*.*')
.pipe(texturePacker())
.pipe(gulp.dest('dest/'));
});
Use packer options object
let texturePacker = require('gulp-free-tex-packer');
gulp.task('pack', function() {
return gulp.src('src/**/*.*')
.pipe(texturePacker({
textureName: "my-texture",
width: 1024,
height: 1024,
fixedSize: false,
padding: 2,
allowRotation: true,
detectIdentical: true,
allowTrim: true,
exporter: "Pixi",
removeFileExtension: true,
prependFolderName: true
}))
.pipe(gulp.dest('dest/'));
});
Pack options description: https://github.com/odrick/free-tex-packer-core#available-options
Custom exporters description: https://github.com/odrick/free-tex-packer-core#custom-exporter
- Free texture packer core - https://github.com/odrick/free-tex-packer-core
License: MIT