[vtkusers] VTK/Java + rendering issue

Alexandre Dufour adufour at pasteur.fr
Thu May 22 13:34:37 EDT 2014


Thanks a lot Sebastien for your input, I’m glad Java isn’t left aside!

As a quick heads up to our previous discussion on this form, I had been trying the JOGL integration myself (still on VTK 5.x though) and went pretty far, but seeing your post (and self answer), I’m still a bit puzzled by which path to take.

When you mention that “On the AWT side, it is better”, I assume that has no positive impact on the lightweight/heavyweight issue, which remains unchanged?

Also, has there been any changes from 5.x to 6.x in this particular area?

Thanks again for the support!
Alexandre

---
Alexandre Dufour, Ph.D.
Institut Pasteur - Bio Image Analysis Group
25, rue du Docteur Roux, Paris, France
Research: http://www.bioimageanalysis.org/dufour
Software: http://icy.bioimageanalysis.org

On 22 May 2014, at 18:27, Sebastien Jourdain <sebastien.jourdain at kitware.com> wrote:

> I guess I'll answer to myself. ;-)
> 
> So the JOGL render has definitely an issue when VTK tries to read or write into the pixel buffer. And I don't have a solution for that. This must be a JOGL related issue.
> 
> This mean the following features won't work:
> - Screen capture (Using VTK code)
> - Rubber band type of interaction where a rectangle get drawn on top of window.
> - Volume rendering
> 
> On the AWT side, it is better. My issue was related to the fact that my Windows system was using its integrated GPU instead of the Nvidia one. Once I changed to use the Nvidia one, everything was fine.
> 
> Have a great day!
> 
> Seb
> 
> 
> 
> On Tue, May 20, 2014 at 9:32 AM, Sebastien Jourdain <sebastien.jourdain at kitware.com> wrote:
> Hi everyone,
> 
> I've been working on VTK and its Java wrapping lately.
> 
> Before getting into the details of my issue, I wanted to give you an update on the work that I've done in the last couple months for you.
> 
> I've started an automated the process to build VTK/Java binaries package for all the platforms. The full process is not yet polished but you can already download on our VTK dashboard a compiled version of VTK master specially packaged for Java.
> To get a specific version, just click on the yellow box of the targeted platform on the following page.
> 
> http://open.cdash.org/index.php?project=VTK
> 
> I've also worked on rendering components based on JOGL to overcome the rendering issue that was happening on Mac with Java 7+ due to API change inside the JVM and its management of the windowing system.
> 
> Thanks to the JOGL cross platform support, those classes can be used on Windows, Mac and Linux.
> 
> The idea behind those classes were to rely on JOGL to create the OpenGL context and deal with the Java windowing system. So VTK could just focus on feeding that OpenGL context like we do with Qt.
> 
> The original integration is relying on the capability to "paste" an overlay native window content into an AWT canvas.
> 
> Both integration works cross platform except the last one on Mac when using the JVM from Oracle.
> 
> To ease my explanation lets call the 2 rendering/integration technics with the following names: JOGL and AWT.
> 
> So here are the issues that I've discovered on which I would love to have some insight.
> 
> Using the JOGL renderer, the rendering is behaving as expected except when VTK tries to directly interact with the pixel buffer. This happen when using some rubber band interactor style that aim to draw a dynamic rectangle inside the window. 
> 
> Here is what's happening on each platform:
> - OSX: The rectangle does not show but the application still work and behave as expected.
> - Linux: Same as OSX. 
> - Windows: The rectangle does not show but the application freeze.
> 
> Using the AWT renderer, the rendering is behaving as expected specially with the rubber band interactor. But when trying to render any 2D actor (scalarbar, text), those don't even show up on Windows. I still have to see how it behave on Linux.
> 
> But in the mean time if anyone has any clue on how to handle either issue, I would love to hear from you.
> 
> Thanks for your help,
> 
> Seb
> 
> PS: I've also tried several JVM options without any success.
> => http://www.oracle.com/technetwork/java/javase/java2d-142140.html
> 
> 
> _______________________________________________
> Powered by www.kitware.com
> 
> Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html
> 
> Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ
> 
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20140522/a048216a/attachment.html>


More information about the vtkusers mailing list