{"_id":"@aidinabedi/texture-compressor","_rev":"1-77472a9047165b8a1be609ec7c6052b5","name":"@aidinabedi/texture-compressor","dist-tags":{"latest":"1.0.2"},"versions":{"1.0.2":{"name":"@aidinabedi/texture-compressor","version":"1.0.2","description":"CLI tool for texture compression using ASTC, ETC, PVRTC and S3TC in a KTX container.","main":"dist/cli/lib/index.js","types":"dist/types/lib/index.d.ts","scripts":{"start":"tsc -w","lint":"tslint --project tsconfig.json -t codeFrame 'src/**/*.ts' 'test/**/*.ts'","prebuild":"rimraf dist","build":"tsc"},"bin":{"texture-compressor":"./bin/texture-compressor.js"},"author":{"name":"Tim van Scherpenzeel"},"license":"MIT","dependencies":{"argparse":"^1.0.10","image-size":"^0.7.4"},"devDependencies":{"@types/argparse":"^1.0.36","@types/node":"^12.0.2","prettier":"^1.17.1","rimraf":"^2.6.3","tslint":"^5.16.0","tslint-config-prettier":"^1.18.0","typescript":"^3.4.5"},"prettier":{"semi":true,"singleQuote":true,"trailingComma":"es5","printWidth":100},"gitHead":"13f029e7c8ea4750af036ac94f08aa82b66ed50f","_id":"@aidinabedi/texture-compressor@1.0.2","_npmVersion":"6.4.1","_nodeVersion":"10.11.0","_npmUser":{"name":"aidinabedi","email":"aidinabedi@gmail.com"},"dist":{"integrity":"sha512-j70BAsYQ6rwpn31nU+KK/e9lpaNd0DX8VcybXBb6sQwwZNJpBQoMnN6zG3Yl4h7421PS6mWUfn11+wXV5A3HkQ==","shasum":"12ab69f78288281bfaddb9d7272a630b955b50cc","tarball":"https://registry.npmjs.org/@aidinabedi/texture-compressor/-/texture-compressor-1.0.2.tgz","fileCount":78,"unpackedSize":33510216,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJduzooCRA9TVsSAnZWagAAySkP/iaeioHrSNX9sLquEUo0\nrNbAUcvqV2qceGP4IfsZZJf83eWLylcnjons8EgZC6HJzil13O2kqlnLt28N\n4fyf/I1JghFtK8qZB55M/A4qKRk90tzEoPyVF6MctOGRUT3Ssz8E+6i11HQI\nGN+QfgsKPtmNKqn42TGnQhY5HaZTUIdQ9B/uf1K+McSQhn9y5odgfJKdBCAT\nVy8b91+HGU2s0+vetwTCfrg9xr7n6Mv1XQvIfOgQ7UOz5z1nc1LuaOAjVmk4\nlrLF4buOEBINWMom4BtajK2x8IaWIvbo3stuHeZHnNwyC8JmbllFJ3GHL+Qy\n7C4FWhh0PfDJj3xnp8pRwaEdpaPb1iUiFHNMIZTzZWIGRszKCYpGLBhojD7p\nmZCb1hdewaikuIhwlwwwa8cQdVMZTInQl6mS4zAWYjR74o1yaNxQwlqyKCcu\n2OopC4nO8EdtLyCGxqWBjWbpg06SWsc9FoiP4AIKfpOAqh2oNcMo2WFHMt0O\nZx4SjFNbUcG+F8REo50tvz0JJ76ERFZSebv4bizITnXh+pHj9z+tHaxWEf6v\nfowYcioq+9ErEgII/rkNqRa1Q2mXLDJ6DBC++Nx5WaudBb9CcKNsgGb4Yr7Q\naTiqk1WYl3s/Pl+nX6qNvfHI/oGdYTE8kqEJ8kWu9aUiUkjiSkpl38VJLBXB\ns/Ko\r\n=iVrj\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDavvjHyWy+4t9SRLAFr10ilMeyilCmNWT1JdgEo5UKHQIhALSsgItEnaZtWWwcs7AIyA2UHgZKRhjXn5/sAUTU9N1b"}]},"maintainers":[{"name":"aidinabedi","email":"aidinabedi@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/texture-compressor_1.0.2_1572551208000_0.017212300021795413"},"_hasShrinkwrap":false}},"time":{"created":"2019-10-31T19:46:47.786Z","1.0.2":"2019-10-31T19:46:48.562Z","modified":"2022-04-04T12:17:01.237Z"},"maintainers":[{"name":"aidinabedi","email":"aidinabedi@gmail.com"}],"description":"CLI tool for texture compression using ASTC, ETC, PVRTC and S3TC in a KTX container.","author":{"name":"Tim van Scherpenzeel"},"license":"MIT","readme":"# Texture Compressor\r\n\r\n[![npm version](https://badge.fury.io/js/texture-compressor.svg)](https://badge.fury.io/js/texture-compressor)\r\n\r\nCLI tool for texture compression using ASTC, ETC, PVRTC and S3TC in a KTX container.\r\n\r\n## Installation\r\n\r\nMake sure you have [Node.js](http://nodejs.org/) installed.\r\n\r\n```sh\r\n $ npm install texture-compressor\r\n```\r\n\r\n## Live demo\r\n\r\n[Live demo](https://timvanscherpenzeel.github.io/texture-compressor/)\r\n\r\n## Documentation\r\n\r\n[Supported devices table](docs/SUPPORTED_DEVICES_TABLE.md)\r\n\r\n[Supported parameters](docs/SUPPORTED_PARAMETERS.md)\r\n\r\n[Recommended parameters](docs/RECOMMENDED_PARAMETERS.md)\r\n\r\n## CLI Usage\r\n\r\n### ASTC\r\n\r\n```sh\r\n$ node ./bin/texture-compressor -i input/example.png -t astc -c ASTC_4x4 -q astcmedium -o output/example-astc.ktx -y -m -vb\r\n```\r\n\r\n### ETC\r\n\r\n```sh\r\n$ node ./bin/texture-compressor -i input/example.png -t etc -c ETC2_RGB -q etcfast -o output/example-etc.ktx -y -m -vb\r\n```\r\n\r\n### PVRTC\r\n\r\n```sh\r\n$ node ./bin/texture-compressor -i input/example.png -t pvrtc -c PVRTC1_2 -q pvrtcnormal -o output/example-pvrtc.ktx -y -m -vb\r\n```\r\n\r\n### S3TC\r\n\r\n```sh\r\n$ node ./bin/texture-compressor -i input/example.png -t s3tc -c DXT1 -q normal -o output/example-s3tc.ktx -y -m -vb\r\n```\r\n\r\n## Module usage\r\n\r\n```js\r\nconst { pack } = require('./dist/cli/lib/index');\r\n\r\npack({\r\n  type: 'astc',\r\n  input: 'input/example.png',\r\n  output: 'output/example-astc.ktx',\r\n  compression: 'ASTC_4x4',\r\n  quality: 'astcmedium',\r\n  verbose: true,\r\n}).then(() => console.log('done!'));\r\n```\r\n\r\n## Flags\r\n\r\n### Required\r\n\r\n    -i, --input [example: ./input/example.png] [required]\r\n    -o, --output [example: ./output/example.ktx] [required]\r\n    -t, --type [example: astc, etc, pvrtc, s3tc] [required]\r\n    -c, --compression [example: ASTC_4x4, ETC2_RGB, PVRTC1_2, DXT1] [required]\r\n    -q, --quality [example: astcmedium, etcfast, pvrtcnormal, normal] [required]\r\n\r\n### Optional\r\n\r\n    -vb, --verbose [true / false, default: false] [not required]\r\n\r\n    -rs, --square ['no', '-', '+', default: +] [not required]\r\n    -rp, --pot ['no', '-', '+', default: +] [not required]\r\n    -m, --mipmap [true / false, default: false] [not required]\r\n    -y, --flipY [tue / false, default: false] [not required]\r\n\r\n### Tool flags\r\n\r\nTool flags are not processed by `texture-compressor` but rather directly by the binary you are targeting itself.\r\n\r\nFor example adding `--flags [\"usesourceformat DXT1A\" \"alphaThreshold 200\"]` will pass `usesourceformat DXT1A` and `alphaThreshold 200` directly to `Crunch`.\r\n\r\nPlease be aware that these flags are tool specific and can therefore not be directly applied to the other binaries.\r\n\r\n    -f, --flags [\"flag value\" \"flag value\"] [not required]\r\n\r\nTo find tool specific flags please refer to the manuals of [ASTC](http://cdn.imgtec.com/sdk-documentation/PVRTexTool.User+Manual.pdf), [ETC](http://cdn.imgtec.com/sdk-documentation/PVRTexTool.User+Manual.pdf), [PVRTC](http://cdn.imgtec.com/sdk-documentation/PVRTexTool.User+Manual.pdf), [S3TC](https://github.com/BinomialLLC/crunch/blob/235946f7a1cf8b9c97e8bf0e8062d5439a51dec7/crunch/crunch.cpp#L70-L181).\r\n\r\n## License\r\n\r\nMy work is released under the [MIT license](https://raw.githubusercontent.com/TimvanScherpenzeel/texture-compressor/master/LICENSE).\r\n\r\nThis repository distributes multiple binary tools for Windows, Mac and Linux.\r\nThis product includes components of the PowerVR™ SDK from Imagination Technologies Limited.\r\n\r\n- [astcenc](https://raw.githubusercontent.com/ARM-software/astc-encoder/master/license.txt)\r\n- [PVRTexToolCLI](https://community.imgtec.com/developers/powervr/sdk-end-user-licence-agreement/)\r\n- [crunch](https://raw.githubusercontent.com/BinomialLLC/crunch/master/license.txt)\r\n","readmeFilename":"README.md"}