How kennycha/phy-topster works
Main Components
a. Client-Side Application Structure:
• Rendering Engine (Three.js)
• Physics Engine (Cannon-es)
• Core Components
• State Management
• Asset Management
Detailed Component Breakdown
Core Components Layer:
• With the physics and rendering engines
• Relationship to shader systems (vertex.glsl and fragment.glsl)
Asset Management:
• Connection to public/assets directory
State Management:
• Observer pattern implementation
• How it connects to core components
[Browser Environment]
• ↓
[Vite Development Server]
• ↓
[Application Entry (main.ts)]
[Three.js Renderer] ←→ [Cannon-es Physics]
• ↓
[Core Components]
[Asset Management] → [State Management]
Important Details to Capture
• How the shader system (vertex.glsl and fragment.glsl) integrates with Three.js
• Relationship between physics objects and their visual representations
• Demonstrate how the observer pattern manages state changes
• Asset loading pipeline from public directory to runtime usage
Technical Stack Representation
[TypeScript]
[Three.js / Cannon-es]
[WebGL]
[Browser Runtime]
Development Tooling (Secondary Layer)
• Vite's role in development
• TypeScript compilation process
• Demonstrate GitHub Pages deployment flow