A collection of code examples for a step-by-step WebGL 2 tutorial series, ranging from a basic full-screen quad (Article 2) up to a real-time fluid simulation (Article 6).
Article 2: WebGL 2 Basics:
-
Article 3: Rendering to Textures with Framebuffers
-
Article 4 Stateful Rendering with the Ping-Pong Technique
-
Article 5: Fluid Simulation in WebGL - The Advection Step
-
Article 6: WebGL Fluid Simulation: Pressure Solving
Each folder contains a self-contained example for its corresponding article.
To load shaders from external files, run a minimal HTTP server. From the project root:
cd web-gl-series
python3 -m http.server 8000Then open an example in your browser:
http://localhost:8000/<article-name>/index.html