{"id":15287950,"url":"https://github.com/andstor/three-voxel-loader","last_synced_at":"2025-04-13T06:08:13.174Z","repository":{"id":42930299,"uuid":"233962521","full_name":"andstor/three-voxel-loader","owner":"andstor","description":":framed_picture: three.js plugin for loading voxel data","archived":false,"fork":false,"pushed_at":"2023-01-06T02:32:35.000Z","size":2220,"stargazers_count":30,"open_issues_count":16,"forks_count":11,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-04-13T06:07:35.875Z","etag":null,"topics":["threejs","threejs-loader","visualization","voxel","voxel-data"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/three-voxel-loader","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/andstor.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-01-15T00:20:34.000Z","updated_at":"2025-01-09T07:51:15.000Z","dependencies_parsed_at":"2023-02-05T03:16:57.602Z","dependency_job_id":null,"html_url":"https://github.com/andstor/three-voxel-loader","commit_stats":null,"previous_names":[],"tags_count":10,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andstor%2Fthree-voxel-loader","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andstor%2Fthree-voxel-loader/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andstor%2Fthree-voxel-loader/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andstor%2Fthree-voxel-loader/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/andstor","download_url":"https://codeload.github.com/andstor/three-voxel-loader/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248670435,"owners_count":21142904,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["threejs","threejs-loader","visualization","voxel","voxel-data"],"created_at":"2024-09-30T15:39:54.795Z","updated_at":"2025-04-13T06:08:13.124Z","avatar_url":"https://github.com/andstor.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# three-voxel-loader\n\n\u003e three.js plugin for loading voxel data\n\n[![npm version](http://img.shields.io/npm/v/three-voxel-loader.svg?style=flat)](https://npmjs.org/package/three-voxel-loader \"View this project on npm\")\n![Build](https://github.com/andstor/three-voxel-loader/workflows/Build/badge.svg)\n[![Coverage Status](https://coveralls.io/repos/github/andstor/three-voxel-loader/badge.svg?branch=master)](https://coveralls.io/github/andstor/three-voxel-loader?branch=master)\n[![Language grade: JavaScript](https://img.shields.io/lgtm/grade/javascript/g/andstor/three-voxel-loader.svg?)](https://lgtm.com/projects/g/andstor/three-voxel-loader/context:javascript)\n\nThis is a plugin for [three.js](https://github.com/mrdoob/three.js). It provides support for loading voxel data and turning it into a three.js [Mesh](https://threejs.org/docs/#api/en/objects/Mesh).\n\n[Examples](https://andstor.github.io/three-voxel-loader/examples/) - \n[Documentation](https://andstor.github.io/three-voxel-loader/) - \n[Wiki](https://github.com/andstor/three-voxel-loader/wiki)\n\n## Table of Contents\n\n  * [Preview](#preview)\n  * [Installation](#installation)\n  * [Usage](#usage)\n  * [Import support](#import-support)\n  * [License](#license)\n\n\n## 🖼 Preview\n\n\u003cp align=center\u003e\n\t\u003cimg width=\"450\" src=\"https://raw.githubusercontent.com/andstor/three-voxel-loader/master/media/load-model.png\" alt=\"Preview\"\u003e\n\u003c/p\u003e\n\n## Installation\n\nThis library requires the peer dependency [three.js](https://github.com/mrdoob/three.js/).\n\n```sh\n$ npm install --save three\n```\n\n```sh\n$ npm install --save three-voxel-loader\n```\n\n## Usage\n\n### Syntax\n\n```js\nnew VoxelLoader()\n```\n\n### Example\n\n```js\nconst VoxelLoader = require('three-voxel-loader');\n\n// Instantiate the loader\nlet loader = new VoxelLoader();\n\n// Load a resource from provided URL.\nloader.load(\n  // Resource URL.\n  'models/chicken.vox',\n\n  // Called when resource is loaded.\n  function ( voxels ) {\n    scene.add( voxels );\n  },\n\n  // Called when loading is in progresses.\n  function ( xhr ) {\n    console.log( ( xhr.loaded / xhr.total * 100 ) + '% loaded' );\n  },\n\n  // Called when loading has errors.\n  function ( error ) {\n    console.log( 'An error happened' );\n  }\n);\n```\n\n## Import support\n\nImporting of several file types and data structures with voxel data are supported.\n\n### File formats\n\n- [VOX](https://ephtracy.github.io)\n- XML\n- [BINVOX](https://www.patrickmin.com/binvox/binvox.html)\n\n### Data structures\n\n- 3D array\n- [Sparse octree](https://github.com/vanruesc/sparse-octree)\n\n## License\n\nCopyright © 2020 [André Storhaug](https://github.com/andstor)\n\nthree-voxel-loader is licensed under the [MIT License](https://github.com/andstor/three-voxel-loader/blob/master/LICENSE).\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fandstor%2Fthree-voxel-loader","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fandstor%2Fthree-voxel-loader","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fandstor%2Fthree-voxel-loader/lists"}