ITADN

Image and HDR skybox backgrounds star-burst at the poles (equirect on a sphere, not a cube)

#185Openbdero 创建于 2026-06-28
renderingbug
B
bderocommented
The visible skybox background for an image or HDR environment samples the source equirectangular image directly with a spherical-to-equirect mapping, so it pinches at the poles and shows star-bursting there. It also reads as low resolution because it is limited by the equirect source resolution rather than a cube. In `shaders/flutter_scene_skybox_environment.frag` the sharp background path reads `uniform sampler2D environment_background` via `SphericalToEquirectangular(direction)` when `has_background > 0.5`. The prefiltered radiance is already a cube (`samplerCube prefiltered_radiance_cube`), but the sharp background path deliberately uses the raw equirect source for sharpness, which is what introduces the pole distortion. Expected behavior. The sharp skybox background should sample a cube map so it stays sharp and free of pole star-bursting. One fix is to convert the source equirect into a sharp cube once at load, kept separate from the GGX-prefiltered radiance cube, and sample that cube for the `has_background` path. Notes. The example app's Car scene uses a 1024x512 source, which compounds the low-resolution look. The editor imports HDRs at up to 4096 wide, which is sharper but still pole-pinched, since the background sampling path is the same. There is no cube-map background path today. Repro. Load an image or HDR environment with a skybox and look toward the top or bottom pole.
0 条评论