Skip to content

imMokiya/black_hole

Repository files navigation

Black Hole Using C++

A super fast space simulator that runs on your GPU. It shows how a black hole bends light (gravity!) in real time.

Controls

  • Mouse Move: Look around.
  • Scroll: Zoom in and out.
  • G Key: Turn the gravity/curved light ON or OFF.
  • Right Click: Hold this to make objects fall into the black hole.

How to run (Windows)

  1. Keep all files in one folder (the .exe, .comp, .vert, .frag, and .dll).
  2. Double click bh_raytrace.exe or any of the other simulations and have fun playing around!
  3. If it feels slow, don't worry! It's doing a lot of math.

How to build

If you have MSYS2/Clang installed, just open a terminal in this folder and type: make or in powershell mingw32-make

Compatibility

All files are compatible on Windows 11, Linux and MacOS. It should run on most weak CPUs/GPUs.

About

Raytracing a black hole in 3D with C++ and OpenGL

Topics

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors