init repository with p5js and babylon

This commit is contained in:
pobadoba
2026-05-05 18:17:28 +09:00
commit 66f5f35a9e
13 changed files with 1682 additions and 0 deletions

16
src/multi_sketch.js Normal file
View File

@@ -0,0 +1,16 @@
import * as BABYLON from "babylonjs";
const canvas = document.getElementById("renderCanvas");
const engine = new BABYLON.Engine(canvas, true);
const scene = new BABYLON.Scene(engine);
const camera = new BABYLON.ArcRotateCamera("cam", 0, 0, 10, BABYLON.Vector3.Zero(), scene);
camera.attachControl(canvas, true);
const light = new BABYLON.HemisphericLight("light", new BABYLON.Vector3(0, 1, 0), scene);
const sphere = BABYLON.MeshBuilder.CreateSphere("sphere", {}, scene);
engine.runRenderLoop(() => {
scene.render();
});