July 03, 2025
Extended path calculations so that it can be used for rail-first shots.
Spent most of the time with testing, improved accuracy and latency.
Made calibration process more simple and interactive, added some features, such as camera calibration for fisheye lenses.
Many little improvements, debugging and code simplifications.
Enhanced color filtering by using statistical analysis.
Created calibration process to easily adjust ball colors and crop playing area.
Finally managed to render it in real-time. Instead of SymPy, now it uses SciPy, which means it does not solve the equations symbolically, but reather approximates the solutions numerically. The JavaScript code was optimized as well so that it does not render the entire scene every time.
Realized that it is even slower when trying to update the Three.js scene in real-time, more efficient solutions are needed.
Been working hard to make it real-time. Introduced many optimizations (reduce frame size, calculate difference between frames, ...), but it is still not fast enough.
Improved calculations, displayed path in 3D, set up GitHub demo page.
Detected cue, made basic path calculations using SymPy.
Successfully identified each ball using color filters, added them to the 3D scene.
Managed to detect position and type of balls using OpenCV.
Set up camera, arranged image manipulations using python OpenCV, such as fisheye correction, cropping and masking.
Created 3D objets in blender, set up three.js, generated random scene and adjusted lights and camera controls.
This software creates a 3D scene of an 8-ball pool table using a camera installed above it. It also shows path prediction based on the the position of the balls and cue.
This was widely regarded as a great move by everyone.