See codepen: https://codepen.io/Eric2048/pen/QwEjBLB
This is using WebGPURenderer and its ClippingGroup support, on Mac OSX Chrome 143.0.7499.170.
cube0 (green) is not clipped and just provides a reference (x: -200 to +200).
cube1 (blue) is also 400 wide and should be clipped at x = 0 (the portion left of 0 clipped).
cube2 (red) is also 400 wide and should be clipped at x = -100 (the portion left of -100 clipped).
The cubes don’t share any aspects of their materials or geometries, and the localPlanes are independent.
The issue: with clipping enabled for cube1 and cube2, cube2 appears to be clipped by cube1’s localPlane1.
If you disable clipping for cube1, cube2 shows the proper clipping.
If you add cube3 to the mix, it will be clipped by cube1 or cube2, whichever has a higher x value for its localPlane.
Also note the weird results when setting clipIntersection true/false across the 2 or 3 ClippingGroups – might be a workaround if there were only two ClippingGroups but not for 3+.
I understand that clipping works using world (absolute) coordinates for its clipping plane, but I would think that when using a ClippingGroup, the clipping would be limited to the descendants of the ClippingGroup.
Thanks, Eric