40M cubes with individual opacity and color

I made a post about it some time ago, you can add individual opacities to instanced geometry but it requires modifying a few lines of code in the library (not sure if there has been any progress in regards to instanced geometry since then):

You can first render your image in black and white on a render target and then add another pass that maps brightness into a color using some formula, and render that onto canvas (using render target as an input texture), that’s pretty easy to do, probably adds one extra draw call. You can write a simple ShaderMaterial for that purpose.

1 Like