Possible 9.6.0 regression with environment texture rendering

The following script loads a cube map as a skybox environment texture and plots a metallic sphere with PBR.

env_texture.py (2.8 KB)
cubemap_park.zip (592.7 KB)

Usage: download script and unzip cubemap files. Then run

python env_texture.py cubemap_park

With vtk==9.5.2, we get this image, where the reflection is showing what’s behind the camera. This appears correct to me.

But with vtk==9.6.0rc2, we get this instead, where the reflection is showing the same contents as the foreground image.

This seems like a regression, but I am not sure… maybe someone can comment on whether this is a bug or is intentional?

By installing the dev wheels, I was able to confirm that we get the first image with vtk==9.5.20250830.dev0, and we get the second with vtk-9.5.20250913.dev0, so the change occurred between Aug 30 and Sept 13.

I think perhaps this commit may be the cause of the change?
https://gitlab.kitware.com/vtk/vtk/-/commit/2ec9432207980adf303e2266d4c5485f638a4269
I believe it was committed to master Sep 8.

@LucasGandel @lgivord

I reproduce the issue on Linux too, I’ll take a look.

Thanks also for the bisect, it’s very useful :slightly_smiling_face:

here is the issue : https://gitlab.kitware.com/vtk/vtk/-/issues/19910