Login  Register

Re: Java3D to Jogamp Ardor3D Continuation...

Posted by ThomasR on Nov 23, 2016; 8:43pm
URL: https://forum.jogamp.org/Java3D-to-Jogamp-Ardor3D-Continuation-tp4036855p4037452.html

Hi,

JoglSwingCanvas works very well in my simple JSplitPane demo, I applied your suggestion to update the viewport
on component resize events. But there are problems with JoglAwtCanvas and JoglNewtAwtCanvas:



Shows the initial layout with a blank JPanel on the left and a JoglAwtCanvas on the right, but when the divider is moved to the left:



The canvas does't appear to fill to the divider. Though interestingly checking the canvas size on component changed events the canvas.getSize() matches what the area should be. Mouse events are also sent to the logicalLayer from the
blank area in the left side component. So the canvas thinks it's the correct size, any idea what's not the correct size? Here's what happens dragging the divider to the right:



Just looking at these images, what might be wrong? Is there a difference between how the Swing and AWT canvases
respond to the layout manager? I tried forcing revalidate and validate, but no luck. Is this problem deeper down to JOGL itself? It's very encouraging that the SwingCanvas works very well, and that the AWT and NewtAwt canvases, even though things don't work as expected, don't core dump. Where are we going to have to start digging to make these work in Split and Tabbed Panes?

Tom