Class CubeMapToSphericalPolynomialTools
Methods
StaticConvert Cube Map Texture To Spherical Polynomial
-
ConvertCubeMapTextureToSphericalPolynomial(
texture: BaseTexture,
): Nullable<Promise<SphericalPolynomial>>Converts a texture to the according Spherical Polynomial data. This extracts the first 3 orders only as they are the only one used in the lighting.
Parameters
- texture: BaseTexture
The texture to extract the information from.
Returns Nullable<Promise<SphericalPolynomial>>
The Spherical Polynomial data.
- texture: BaseTexture
StaticConvert Cube Map To Spherical Polynomial
-
ConvertCubeMapToSphericalPolynomial(
cubeInfo: CubeMapInfo,
targetSize?: number,
): SphericalPolynomialConverts a cubemap to the according Spherical Polynomial data. This extracts the first 3 orders only as they are the only one used in the lighting.
Parameters
- cubeInfo: CubeMapInfo
The Cube map to extract the information from.
- targetSize: number = 0
Optional target face size for downsampling before integration. 0 = no downsampling (default).
Returns SphericalPolynomial
The Spherical Polynomial data.
- cubeInfo: CubeMapInfo
Helper class dealing with the extraction of spherical polynomial dataArray from a cube map.