Getting Spherical Harmonics straight from equirectangular image


I want to make a spherical harmonics from a equirectangular HDR image but it seems LightProbeGenerator currently only takes a cube map as parameter to make a spherical harmonics.

I know I can convert HDR into cube map first and then use LightProbeGenerator but I want to avoid unnecessary intermediate steps as long as I can.

Are there any Plugin / code snippet / discussion I can refer ?

AFAIK, no. The intended workflow is the usage of WebGLCubeRenderTarget.fromEquirectangularTexture() to convert the environment map to the cube map format. In the next step, use the render target with LightProbeGenerator.fromCubeRenderTarget().