Experience an out-of-this-world black hole simulation online. This project was created using only WebGPU and TypeScript, without a game engine, and it brings one of the greatest mysteries in our universe straight to your browser. It features a simulation based on real physics from the Einstein Field Equations. More specifically, this project uses the Kerr Metric, which describes the curvature of spacetime around a rotating black hole. To top it all off, the simulation presents ray-traced visuals and carefully adjusted post-processing effects, all so you'll be able to observe the beauty of gravitational lensing, accretion disks, and more.
bovizdb
Check their projects out: CardChess, 8-ball pool 3D visualizer
Once you ship this you can't edit the description of the project, but you'll be able to add more devlogs and re-ship it as you add new features!
Can't believe it took almost 4 hours to ray trace a simple black hole. Granted, this is different to traditional ray tracing, which mathematically calculates if it intersects with shapes. This ray tracer is closer to ray marching than it is ray tracing so far, since it marches the ray forward a certain distance and checks to see if it's inside the black hole. If it is, then the pixel is black.
Initial commit! I couldn't be bothered writing out a bunch of code I've written before (for cameras, ray tracing, skyboxes, etc) so I copied code from a few previous projects. However, a lot of the classes require other classes (shared between projects) with different interfaces, which made combining all the code a pain. Maybe I should've just written it all out by hand. But that aside, we have a skybox! It's currently just the Milky Way, and there aren't any black holes yet. But everything is super buggy still (moving the camera breaks it instantly) and the code is a mess since it's all copied.