Skip to content

Instantly share code, notes, and snippets.

@donmccurdy
donmccurdy / FOO2GLTF.js
Last active August 1, 2023 06:53
Example Node.js glTF conversion script, using three.js.
#!/usr/bin/env node
const fs = require('fs');
const path = require('path');
const THREE = require('three');
const program = require('commander');
const Canvas = require('canvas');
const { Blob, FileReader } = require('vblob');
// Patch global scope to imitate browser environment.