Skip to content
프로젝트

achrefelouafi/BuildingGeneratorThreeJS

GitHub에서 보기

소개

A procedural Hong Kong building generator for Three.js, ported from a Blender geometry-nodes setup (procedural-hong-kong-building/source/procedural_building.blend). Original model URL : https://sketchfab.com/3d-models/procedural-hong-kong-building-528a732e84c44fd49c4726f341014a23

개발 도구

이 수치를 측정하는 방법

측정된 스타 증가

in 24h
+2
in 7 days
+7
in 15 days
+9
in 1 month
기록 수집 중

서로 겹치는 기간의 순증가량이며 일별 합계가 아닙니다. 측정값이 없으면 비워 둡니다. 스타는 관심도를 나타내며 품질을 보장하지 않습니다.

README.md

Original

BuildingGeneratorThreeJS

A procedural Hong Kong building generator for Three.js, ported from a Blender geometry-nodes setup (procedural-hong-kong-building/source/procedural_building.blend). Original model URL : https://sketchfab.com/3d-models/procedural-hong-kong-building-528a732e84c44fd49c4726f341014a23

The original 592-node "build system" node group was reverse-engineered into a TypeScript placement algorithm (docs/BUILD_SYSTEM.md); the ~190 building parts (walls, windows, AC units, clotheslines, storefronts, roof props…) are exported from the .blend into a single instanced asset kit (public/assets/kit.glb + kit_manifest.json).

Run

npm install
npm run dev

All 18 generator parameters from the Blender modifier (floors, footprint, AC/clothline/ lights probabilities, window type & open amount, curtains, store state, seed, low-poly toggle…) are exposed as live sliders.

Re-exporting the asset kit

If you edit assets in the .blend, re-run the export (Blender 4.2+):

blender --background procedural-hong-kong-building/source/procedural_building.blend \
        --python tools/export_kit.py -- public/assets/kit.glb public/assets/kit_manifest.json

Structure

  • src/generator.ts — the ported node graph: grids, seeded RNG, placements
  • src/kit.ts — GLB kit loader + InstancedMesh builder
  • src/rng.ts — Blender-style hash(id, seed) random values
  • src/main.ts — scene, lighting, lil-gui controls
  • tools/ — Blender headless scripts (kit export, node-graph dump)

관련 프로젝트 살펴보기

불러오는 중…