chroma-cam

Visualize neutrino detectors in the browser with meshes

A demo of the chroma-cam tool can be found below. Click the “load dichroicon” button; shown will be the exact setup described in the paper Spectral Photon Sorting For Large-Scale Cherenkov and Scintillation Detectors.

The json file contains a list of unique meshes, their colors, and their positions for placement in the scene. You can see an example of the structure of the json file below.

Example: single green triangle { "meshes": [{ "position": [[0.0, 0.0, 0.0]], // mesh offset from origin "orientation": [[[1.0, 0.0, 0.0], // mesh rotation matrix [0.0, 1.0, 0.0], [0.0, 0.0, 1.0]]], "submeshes": [{ // usually more than one "vertices": [[0.0, 0.0, 0.0], [0.0, 0.0, 1.0], [0.0, 1.0, 0.0]], "faces": [[0, 1, 2]], "color": 65280 // in hex, this is 0x00FF00 }] }] }

Like in chroma, solid instancing has been implemented, so that no single triangle in a scene is unneccesarily duplicated more than once. This allows for very large scenes using copies of the same couple meshes to be rendered quickly, and relatively small json files. For example, a full neutrino detector geometry outfitted with around 60,000 PMTs and 30,000 light concentrators is rendered on my M1 MacBook Pro at around 40 fps in Microsoft Edge, and has a json file size of 7.1 MB. In chroma, this entire geometry loaded on the GPU requires around 20 GB of VRAM. In the browser, only around 80 MB of memory is used.