meta-caustics
Real-time Rendering of Deformable Glass with Hand Interaction
本作品は、複数の球が滑らかに融合するガラス状オブジェクト(メタボール)を通した光の屈折と、床に映る虹色の集光模様(コースティクス)をリアルタイムで描画するインタラクティブ作品です。C++とOpenGL/GLSLで実装しています。
一般の条件で正確にコースティクスを求める場合は、例えば光源から大量の光線を飛ばして統計的に求めるフォトンマッピングという手法が用いられますが、ノイズが発生しやすく、計算量も増大するためリアルタイム描画が困難です。本作品では「平面の床・点光源・メタボール」という限定的な条件のもと、床の各点から光源へ逆向きにレイを飛ばし、ガラス内での屈折を近似して追跡を行い、集光度を決定論的に計算しています。これにより、GPUが利用できる環境にて、ノイズのない高解像度コースティクスをフルHDの60fpsで安定して描画することを実現しました。
ハンドインタラクションでは、MediaPipeを用いて手の関節をリアルタイム検出し、握り具合に応じてメタボール同士の反発と引き寄せを制御します。手を開くと広がり、握ると集まり、回すと渦を巻くなど、手にまとわりつくような動きが体験できます。
This work is an interactive piece that renders, in real time, the refraction of light through glass-like metaball objects—formed by smoothly blending multiple spheres—and the resulting rainbow-colored caustic patterns projected onto the floor.
It is implemented in C++ using OpenGL and GLSL.
In general, physically accurate caustics are computed using techniques such as photon mapping, which traces a large number of light rays statistically from the light source. However, these methods tend to introduce noise and require significant computation, making real-time rendering difficult.
In this work, under the constrained conditions of a planar floor, a point light source, and metaball geometry, rays are traced backward from each point on the floor toward the light source. Refraction within the glass object is approximated and tracked deterministically to compute light concentration.
This approach enables stable real-time rendering of noise-free, high-resolution caustics at 60 fps in Full HD on GPU-capable systems.
For hand-based interaction, MediaPipe is used to detect hand joints in real time, and the degree of grip controls attraction and repulsion between the metaballs.
Opening the hand causes the objects to spread apart, while closing it pulls them together; rotating the hand produces a swirling motion, creating an experience in which the metaballs appear to respond organically to the user’s gestures.