{"_id":"parse-dds","_rev":"8-617a646eb94f20aa6603cf81e4524906","name":"parse-dds","description":"parses the headers of a DDS texture file","dist-tags":{"latest":"1.2.1"},"versions":{"1.0.0":{"name":"parse-dds","version":"1.0.0","description":"parses the headers of a DDS texture file","main":"index.js","license":"MIT","author":{"name":"Matt DesLauriers","email":"dave.des@gmail.com","url":"https://github.com/mattdesl"},"dependencies":{},"devDependencies":{"a-big-triangle":"^1.0.0","budo":"^4.0.0","buffer-to-arraybuffer":"0.0.2","garnish":"^2.1.3","gl-basic-shader":"^1.3.0","gl-shader":"^4.0.1","glslify":"^2.1.2","raf-loop":"^1.1.2","tape":"^4.0.0","webgl-context":"^2.1.2","xhr":"^2.0.1"},"scripts":{"test":"node test/index.js","start":"budo demo/index.js --live --verbose -t glslify | garnish"},"keywords":["dds","texture","compressed","webgl","image","format","parse","parses","read"],"repository":{"type":"git","url":"git://github.com/Jam3/parse-dds.git"},"homepage":"https://github.com/Jam3/parse-dds","bugs":{"url":"https://github.com/Jam3/parse-dds/issues"},"gitHead":"d417864ef2d97324fd55c9d730bb9194de6f37e8","_id":"parse-dds@1.0.0","_shasum":"34ebd62b6b56655b40d894ada98672a450ae0ed6","_from":".","_npmVersion":"2.1.18","_nodeVersion":"0.10.32","_npmUser":{"name":"mattdesl","email":"dave.des@gmail.com"},"dist":{"shasum":"34ebd62b6b56655b40d894ada98672a450ae0ed6","tarball":"https://registry.npmjs.org/parse-dds/-/parse-dds-1.0.0.tgz","integrity":"sha512-KxdCn4Wd7lXd8qfbS8sRLLyo3M38J4RBYjGbZjy6xAKPzBCZnP1pxdT9FvmhgBXEMF4MeAnmNKeORySjO0U7Ew==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCICVyoDetQJsIn4iWBxbD/8BuwXgyqCVXWU03s01saasVAiEA1idlel/LhMpNGcL5l7bZ8gobhG/fM6OqHrr+iaPmCAM="}]},"maintainers":[{"name":"mattdesl","email":"dave.des@gmail.com"}]},"1.1.0":{"name":"parse-dds","version":"1.1.0","description":"parses the headers of a DDS texture file","main":"index.js","license":"MIT","author":{"name":"Matt DesLauriers","email":"dave.des@gmail.com","url":"https://github.com/mattdesl"},"dependencies":{},"devDependencies":{"a-big-triangle":"^1.0.0","budo":"^4.0.0","buffer-to-arraybuffer":"0.0.2","garnish":"^2.1.3","gl-basic-shader":"^1.3.0","gl-shader":"^4.0.1","glslify":"^2.1.2","raf-loop":"^1.1.2","tape":"^4.0.0","webgl-context":"^2.1.2","xhr":"^2.0.1"},"scripts":{"test":"node test/index.js","start":"budo demo/index.js --live --verbose -t glslify | garnish"},"keywords":["dds","texture","compressed","webgl","image","format","parse","parses","read"],"repository":{"type":"git","url":"git://github.com/Jam3/parse-dds.git"},"homepage":"https://github.com/Jam3/parse-dds","bugs":{"url":"https://github.com/Jam3/parse-dds/issues"},"gitHead":"0aa3225e6933a1ddafc3d650ea057dafb027132b","_id":"parse-dds@1.1.0","_shasum":"3a8b8dfba741b21db2919fdc35e2e1ad57b983b4","_from":".","_npmVersion":"2.1.18","_nodeVersion":"0.10.32","_npmUser":{"name":"mattdesl","email":"dave.des@gmail.com"},"dist":{"shasum":"3a8b8dfba741b21db2919fdc35e2e1ad57b983b4","tarball":"https://registry.npmjs.org/parse-dds/-/parse-dds-1.1.0.tgz","integrity":"sha512-PmIU2MslcxzJvopfWsvaYvl48uIPKD/Ro2n/rfJXMB/e6uUtyRdM/yE2Zqjh/YwC8ukmB8ZjJG45m81lnBjq5A==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIAwxNtlyaCzWBFfw7Xy/JnzkFKXSJ1AmXRFfDPFIduKJAiEA48C6erF3Rx9QSJ+eqJmzGL4W1htTaPSOdOkhwCK70HE="}]},"maintainers":[{"name":"mattdesl","email":"dave.des@gmail.com"}]},"1.1.1":{"name":"parse-dds","version":"1.1.1","description":"parses the headers of a DDS texture file","main":"index.js","license":"MIT","author":{"name":"Matt DesLauriers","email":"dave.des@gmail.com","url":"https://github.com/mattdesl"},"dependencies":{},"devDependencies":{"a-big-triangle":"^1.0.0","budo":"^4.0.0","buffer-to-arraybuffer":"0.0.2","garnish":"^2.1.3","gl-basic-shader":"^1.3.0","gl-shader":"^4.0.1","glslify":"^2.1.2","raf-loop":"^1.1.2","tape":"^4.0.0","webgl-context":"^2.1.2","xhr":"^2.0.1"},"scripts":{"test":"node test/index.js","start":"budo demo/index.js --live --verbose -t glslify | garnish"},"keywords":["dds","texture","compressed","webgl","image","format","parse","parses","read"],"repository":{"type":"git","url":"git://github.com/Jam3/parse-dds.git"},"homepage":"https://github.com/Jam3/parse-dds","bugs":{"url":"https://github.com/Jam3/parse-dds/issues"},"gitHead":"471bfc133eca59b44f98e787f4252169479c6a8d","_id":"parse-dds@1.1.1","_shasum":"15f5fcf3baa0ed9b1dc2df5ca645aa1644160fbf","_from":".","_npmVersion":"2.1.18","_nodeVersion":"0.10.32","_npmUser":{"name":"mattdesl","email":"dave.des@gmail.com"},"dist":{"shasum":"15f5fcf3baa0ed9b1dc2df5ca645aa1644160fbf","tarball":"https://registry.npmjs.org/parse-dds/-/parse-dds-1.1.1.tgz","integrity":"sha512-2rpRH3FOujl7eIc1IvIlHqLCTfCU1YCaKXeX6w+jkIsntZ6VHM5huIGUjPzh5JFlsXv1c6RioJBKGGrkORVzJg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIDtm6K8pxAGFHJEIpZ9OYtq1Y89Q7KCznlgg7Hizfs7kAiA2MverMNJ7bH+zLYkrBoN0MHi0ACwCMO39jk9ryXHbxw=="}]},"maintainers":[{"name":"mattdesl","email":"dave.des@gmail.com"}]},"1.2.0":{"name":"parse-dds","version":"1.2.0","description":"parses the headers of a DDS texture file","main":"index.js","license":"MIT","author":{"name":"Matt DesLauriers","email":"dave.des@gmail.com","url":"https://github.com/mattdesl"},"dependencies":{},"devDependencies":{"a-big-triangle":"^1.0.0","budo":"^4.0.0","buffer-to-arraybuffer":"0.0.2","garnish":"^2.1.3","gl-basic-shader":"^1.3.0","gl-shader":"^4.0.1","glslify":"^2.1.2","raf-loop":"^1.1.2","tape":"^4.0.0","webgl-context":"^2.1.2","xhr":"^2.0.1"},"scripts":{"test":"node test/index.js","start":"budo demo/index.js --live --verbose -t glslify | garnish"},"keywords":["dds","texture","compressed","webgl","image","format","parse","parses","read"],"repository":{"type":"git","url":"git://github.com/Jam3/parse-dds.git"},"homepage":"https://github.com/Jam3/parse-dds","bugs":{"url":"https://github.com/Jam3/parse-dds/issues"},"gitHead":"78d8237ea5f12524b3c0f4021f24c1c57266bd6c","_id":"parse-dds@1.2.0","_shasum":"fff8ede115936446bf008da6228dc03691d2c0a2","_from":".","_npmVersion":"2.1.18","_nodeVersion":"0.10.32","_npmUser":{"name":"mattdesl","email":"dave.des@gmail.com"},"dist":{"shasum":"fff8ede115936446bf008da6228dc03691d2c0a2","tarball":"https://registry.npmjs.org/parse-dds/-/parse-dds-1.2.0.tgz","integrity":"sha512-gauXtttiG5uU+FtmW3LUro8PdiPhfsrc4Dr2FhxF1RNgJotj6WBU/KubsxNaechq9zpohAfUb38ObJItzhFBag==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDkrlF92eFpYAGIboh1bpEF5gwzyPndFONDDoBahXApZwIhAMwxpWazMYNBsuoOtqWh62gtR9JLMCSXfpKQMx+OKbPk"}]},"maintainers":[{"name":"mattdesl","email":"dave.des@gmail.com"},{"name":"vorg","email":"marcin.ignac@gmail.com"}]},"1.2.1":{"name":"parse-dds","version":"1.2.1","description":"parses the headers of a DDS texture file","main":"index.js","license":"MIT","author":{"name":"Matt DesLauriers","email":"dave.des@gmail.com","url":"https://github.com/mattdesl"},"dependencies":{},"devDependencies":{"a-big-triangle":"^1.0.0","budo":"^4.0.0","buffer-to-arraybuffer":"0.0.2","garnish":"^2.1.3","gl-basic-shader":"^1.3.0","gl-shader":"^4.0.1","glslify":"^2.1.2","raf-loop":"^1.1.2","tape":"^4.0.0","webgl-context":"^2.1.2","xhr":"^2.0.1"},"scripts":{"test":"node test/index.js","start":"budo demo/index.js --live --verbose -t glslify | garnish"},"keywords":["dds","texture","compressed","webgl","image","format","parse","parses","read"],"repository":{"type":"git","url":"git://github.com/Jam3/parse-dds.git"},"homepage":"https://github.com/Jam3/parse-dds","bugs":{"url":"https://github.com/Jam3/parse-dds/issues"},"gitHead":"4abb8a85b35672f58797bc713e58ef83d1829605","_id":"parse-dds@1.2.1","_shasum":"b16533e00c4db91178b3460271361df4cb328164","_from":".","_npmVersion":"2.1.18","_nodeVersion":"0.10.32","_npmUser":{"name":"mattdesl","email":"dave.des@gmail.com"},"dist":{"shasum":"b16533e00c4db91178b3460271361df4cb328164","tarball":"https://registry.npmjs.org/parse-dds/-/parse-dds-1.2.1.tgz","integrity":"sha512-oE88N8mzUi9d26tAaKVc0clxi6AjeTSWpLwgtcEVjXTYY1MW58w8FctmM9gGgvFd6YGu1/eFFYVeDVnlMsKBtA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIFDxEe1FYn8HnqSluYdti2qc3mTwSamIAO1XT6mKMVuTAiEAxaz7WNTmGd/nCD6Gn600hUPU8TR5Nw8RCYZ+ec/lpLI="}]},"maintainers":[{"name":"mattdesl","email":"dave.des@gmail.com"},{"name":"vorg","email":"marcin.ignac@gmail.com"}]}},"readme":"# parse-dds\n\n[![unstable](http://badges.github.io/stability-badges/dist/unstable.svg)](http://github.com/badges/stability-badges)\n\nParses DDS texture headers in Node and the browser. \n\nThis was adapted from [@toji](https://twitter.com/Tojiro)'s wonderful [webgl-texture-utils](https://github.com/toji/webgl-texture-utils/blob/master/texture-util/dds.js). \n\nCurrently this only supports a limited range of common DDS formats: \n\n- DXT1 (RGB)\n- DXT3 (RGBA)\n- DXT5 (RGBA)\n- Cubemaps (RGBA32f) - like those from [cmft](https://github.com/dariomanesku/cmft) and [Modified AMD Cubemapgen](https://seblagarde.wordpress.com/2012/06/10/amd-cubemapgen-for-physically-based-rendering/)\n\nSee [test/index.js](test/index.js) for an example in Node, or [demo/index.js](demo/index.js) for a WebGL compressed texture example.\n\nPull requests welcome.\n\n## Example\n\n```js\nvar parse = require('parse-dds')\n\nvar buffer = new Uint8Array(... DDS file ...)\nvar dds = parse(buffer)\n\nconsole.log(dds.format)  // 'dxt1'\nconsole.log(dds.shape)   // [ width, height ]\nconsole.log(dds.images)  // [ ... mipmap level data ... ]\n\n// get the compressed texture data for gl.compressedTexImage2D\nvar image = dds.images[0]\nvar texture = new Uint8Array(buffer, image.offset, image.length)\n```\n\n## Install\n\n```sh\nnpm install parse-dds --save-dev\n```\n\n## Usage\n\n[![NPM](https://nodei.co/npm/parse-dds.png)](https://www.npmjs.com/package/parse-dds)\n\n#### `dds = parse(arrayBuffer)`\n\nParses an ArrayBuffer and returns the DDS headers for that file.\n\nThe returned values:\n\n- `shape` an array representing the `[ width, height ]` of the texture\n- `flags` the DDS bit flags stored in the file\n- `format` a string, either `'dxt1'`, `'dxt3'`, `'dxt5'` or `'rgba32f'`\n- `images` a list of information to extract sub-arrays for each mipmap level\n- `cubemap` a boolean indicating whether the file contains a cubemap image\n\nEach image has the form:\n\n```js\n{\n  shape: [ width, height ], // size of this mipmap level\n  offset: x,                // byte offset into the input buffer\n  length: len,              // length of this mipmap level image data\n}\n```\n\n## See Also\n\n- [preview-dds](https://github.com/Jam3/preview-dds) for loading and previewing DDS files\n\n## License\n\nMIT, see [LICENSE.md](http://github.com/Jam3/parse-dds/blob/master/LICENSE.md) for details.\n","maintainers":[{"name":"mattdesl","email":"dave.des@gmail.com"},{"name":"vorg","email":"marcin.ignac@gmail.com"}],"time":{"modified":"2022-06-23T10:35:06.699Z","created":"2015-05-25T15:57:12.679Z","1.0.0":"2015-05-25T15:57:12.679Z","1.1.0":"2015-07-07T14:25:33.174Z","1.1.1":"2015-07-07T14:28:29.875Z","1.2.0":"2015-07-07T15:35:33.159Z","1.2.1":"2015-07-08T18:23:20.797Z"},"homepage":"https://github.com/Jam3/parse-dds","keywords":["dds","texture","compressed","webgl","image","format","parse","parses","read"],"repository":{"type":"git","url":"git://github.com/Jam3/parse-dds.git"},"author":{"name":"Matt DesLauriers","email":"dave.des@gmail.com","url":"https://github.com/mattdesl"},"bugs":{"url":"https://github.com/Jam3/parse-dds/issues"},"license":"MIT","readmeFilename":"README.md"}