{"id":18111951,"url":"https://github.com/chr15m/itwriter","last_synced_at":"2025-04-06T08:29:11.890Z","repository":{"id":240257992,"uuid":"802001776","full_name":"chr15m/itwriter","owner":"chr15m","description":"Write Impulse Tracker modules with JavaScript [WIP]","archived":false,"fork":false,"pushed_at":"2024-05-22T15:46:19.000Z","size":33,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-05-22T16:46:42.486Z","etag":null,"topics":["algorave","audio","audio-library","impulse-tracker","impulsetracker","javascript","javascript-library","mod-tracker","music","music-library","tracker-music"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/chr15m.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-05-17T10:25:01.000Z","updated_at":"2024-06-14T14:49:07.290Z","dependencies_parsed_at":"2024-05-22T16:45:36.143Z","dependency_job_id":null,"html_url":"https://github.com/chr15m/itwriter","commit_stats":null,"previous_names":["chr15m/itwriter"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chr15m%2Fitwriter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chr15m%2Fitwriter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chr15m%2Fitwriter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chr15m%2Fitwriter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/chr15m","download_url":"https://codeload.github.com/chr15m/itwriter/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247455833,"owners_count":20941779,"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":["algorave","audio","audio-library","impulse-tracker","impulsetracker","javascript","javascript-library","mod-tracker","music","music-library","tracker-music"],"created_at":"2024-11-01T01:08:55.280Z","updated_at":"2025-04-06T08:29:11.867Z","avatar_url":"https://github.com/chr15m.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"Create Impulse Tracker .it files from a JSON song datastructure.\n\nSee the [browser demo here](https://chr15m.github.io/itwriter) and the node demo in the install section below.\n\n## Install\n\n```\nnpm i itwriter\n```\n\nRun the node example:\n\n```\ncp node_modules/itwriter/example.js .\nnode example.js\nxmp example.it\n```\n\n## Use\n\nBasic usage: `const bytebuffer = itwriter(song_structure)`\n\nMore detailed usage:\n\n```javascript\nimport itwriter from \"itwriter\";\n\n// create a 10ms sinewave sample\nconst sine = [...(new Array(4410))].map((v, i) =\u003e Math.sin(i/10));\n\nconst it = itwriter({\n  \"title\": \"example\",\n  \"bpm\": 120,\n  \"samples\": [{\n    \"name\": \"sine wave\",\n    \"samplerate\": 44100,\n    \"channels\": [sine]\n  }],\n  \"patterns\": [{\n    \"rows\": 32,\n    \"channels\": [{\n      0: {\n        \"note\": \"C-5\",\n        \"instrument\": 0,\n        \"vol\": \"v64\",\n      }\n    }]\n  }],\n  \"order\": [0],\n});\n\n// in Node we can write to disk\nimport fs from \"fs\";\nfs.writeFileSync(\"example.it\", Buffer.from(it));\n\n// in the browser we can download a blob\ndocument.location.href = URL.createObjectURL(new File([it], \"example.it\"));\n```\n\nSee [./example.js](example.js) for a detailed example of the JSON song structure.\n\n## Notes\n\n- Currently only patterns and 16-bit mono/stereo samples are supported, not instruments.\n\n## Technical references used\n\n- \u003chttps://github.com/OpenMPT/openmpt/blob/master/soundlib/Load_it.cpp\u003e\n- \u003chttps://github.com/apollolux/lux-impulse-phoenix/blob/master/ITTECH.TXT\u003e\n- \u003chttps://fileformats.fandom.com/wiki/Impulse_tracker\u003e\n- \u003chttps://github.com/bunnytrack/umx-converter\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchr15m%2Fitwriter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fchr15m%2Fitwriter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchr15m%2Fitwriter/lists"}