JDK-8092948 : Clipping doesn't work for objects in 3D
  • Type: Bug
  • Component: javafx
  • Sub-Component: graphics
  • Affected Version: fx2.0
  • Priority: P3
  • Status: Resolved
  • Resolution: Cannot Reproduce
  • Submitted: 2011-07-15
  • Updated: 2015-06-12
  • Resolved: 2014-01-14
Related Reports
Blocks :  
Blocks :  
Duplicate :  
Relates :  
Relates :  
Relates :  
Relates :  
Description
The attached app creates Rectangle with the custom clip and then rotates it around Y axis. However, the result is really strange.
Comments
RT-30189 fixed the near/far clip issues in JDK 8 b109 (or maybe 110), so if you grab the latest build of JDK 8 it should be fixed there. If not, please file a new bug with a reproducible test case.
18-03-2014

Which build do I need? For me clipping 3D objects does still not work.
18-03-2014

I have verified that the attached 2 clip test programs work well on my NVidia desktop using the latest build. This bug was likely fixed by the near/far clip fix.
14-01-2014

Hi John, Your image test case is incomplete. You need to have a perspective camera and depth buffer for 3D to work. I believe this is a test program bug, however please feel free to file a separate JIRA if you have a valid test case ready.
14-01-2014

Here is another text case which appears to exhibit the same problem. I just see half of the transformed image, similar to how the triangle in the attachment above is cut in half (JavaFX 2.0.1, Win7, JDK7u2, Nvidia GTX460). import javafx.application.Application; import javafx.scene.*; import javafx.scene.image.*; import javafx.scene.transform.Rotate; import javafx.stage.Stage; public class YRotationClippingTest extends Application { public static void main(String[] args) throws Exception { launch(args); } public void start(final Stage stage) throws Exception { final ImageView imageView = new ImageView(new Image("http://bluebuddies.com/smurf_fun/smurf_personality_test/jpg/Painter_Smurf.jpg")); // imageView.setTranslateZ(imageView.getBoundsInLocal().getWidth() / 2.0); // z translate is required otherwise the image will be clipped. imageView.setRotationAxis(Rotate.Y_AXIS); imageView.setRotate(180); stage.setScene(new Scene(new Group(imageView))); stage.show(); } }
06-12-2011

RELEASE NOTE TEXT: Clipping is not well implemented for 3D transformed node. This is a known perspective rendering bug that 3D transformed node may not clip correctly on nVidia and AMD (ATI) GPUs.
31-08-2011

SQE: ok to defer
25-08-2011

3D Clipping is basically broken it is hard to fix is bug before fixing RT-15181. We recommend defer this bug till 3D Clipping is properly implemented in JavaFX.
23-08-2011

I've done some investigation into this bug. Attached is a simple test case that illustrates the bug. It looks like this is a D3D pipe/drive (Nvidia and ATI) bug . This clipping issue doesn't happen on Mac or ES2 pipe on Windows.
29-07-2011

I can verify that on my laptop, this test fails with the NVidia card and works with Intel HD. I think this is a duplicate of RT-14007.
27-07-2011

It works well on my notebook with an Intel HD gpu, but we were able to reproduce the reporter issue on Kirill's notebook with a NVidia gpu. We suspect this might be a far clipping plane issue. Kirill is interested to investigate it further with Alex.
15-07-2011

I was able to reproduce this with NVidia gr board It seems to be different user z-Range in camera space defined for rendering on Intel HD and nVidia systems, We might want to figure out how AMD does. It seems to be a problem with defining Z-range (in camera space ) for a scene. What is defaults for nearZ and farZ values for JavaFX ??
15-07-2011