<div dir="ltr">Hi Marco, <div><br></div><div style>you will have to use another class. But you will have the same integration capability.</div><div style><br></div><div style>Look at src/VTK/Wrapping/Java/vtk/sample/rendering/JoglConeRendering.java for more details.</div>
<div style><br></div><div style>Seb</div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Sep 9, 2013 at 10:37 AM, Marco Sambin <span dir="ltr">&lt;<a href="mailto:m.sambin@gmail.com" target="_blank">m.sambin@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi Seb,<div><br></div><div>this is great news, and I will give it a try!</div><div>One question: will I be able to keep using vtkCanvas as a Java panel class, or rather shall I move to something different?</div>

<div>Thanks again for your feedback.</div><div><br></div><div>Best regards,</div><div><br></div><div>Marco Sambin</div><div><br></div></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><br><div class="gmail_quote">
On Mon, Sep 9, 2013 at 2:45 PM, Sebastien Jourdain <span dir="ltr">&lt;<a href="mailto:sebastien.jourdain@kitware.com" target="_blank">sebastien.jourdain@kitware.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi Marco,<div><br></div><div>you won&#39;t be able to rely on offscreen rendering on Mac to properly handle the issue you are trying to overcome.</div>

<div><br></div><div>Although, a couple of weeks ago, I&#39;ve pushed a new set of classes that works on Mac OS X and Java7 (and on the other of the platforms).</div>
<div>Those classes rely on JOGL to do the rendering. So if adding JOGL as a dependency is not an issue, you can directly use those.</div><div><br></div><div>For that you will need to get VTK/master from git and when you build VTK, you will have to turn ON that component. Moreover if you already download JOGL/GLUGEN using maven, CMake should find the appropriate jars for you.</div>


<div>Otherwise you will need to specify their paths.</div><div><br></div><div>Here is the dependency for Maven.</div><div><br></div><div><div>+                &lt;dependency&gt;</div><div>+                    &lt;groupId&gt;org.jogamp.jogl&lt;/groupId&gt;</div>


<div>+                    &lt;artifactId&gt;jogl-all-main&lt;/artifactId&gt;</div><div>+                    &lt;version&gt;2.0.2&lt;/version&gt;</div><div>+                &lt;/dependency&gt;</div><div>+                &lt;dependency&gt;</div>


<div>+                    &lt;groupId&gt;org.jogamp.gluegen&lt;/groupId&gt;</div><div>+                    &lt;artifactId&gt;gluegen-rt-main&lt;/artifactId&gt;</div><div>+                    &lt;version&gt;2.0.2&lt;/version&gt;</div>


<div>+                &lt;/dependency&gt;</div><div><br></div><div>Hope that could help you,</div><div><br></div><div>Seb</div><div><br></div></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">
On Mon, Sep 9, 2013 at 7:22 AM, Marco Sambin <span dir="ltr">&lt;<a href="mailto:m.sambin@gmail.com" target="_blank">m.sambin@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">


<div dir="ltr">Dear VTKers,<div><br></div><div>I am developing a VTK 6-based Java application, and I am making some efforts to make it compatible with Mac OS X as well.</div><div><br></div><div>I know that the jawt embedding currently supported by Java 7 on Mac (which is CALayer-based) does not work with VTK 6 (nor with previous VTK versions), but there are several portions of my application which do not use direct drawing by VTK classes to Java panels (i.e., do not use jawt), hence will work fine on Mac + Java 7 as well.</div>



<div><br></div><div>Now, for the portions of my application where VTK classes need to actually &quot;draw&quot;, my question is: will offscreen rendering work on Mac? The basic idea would be to grab the output of the offscreen rendering, convert it to a Java-compatible image, and draw it to a Java panel. I know this will be a significant performance penalty, but my requirements in this moment are not so strict or demanding under this point of view.</div>



<div><br></div><div>In particular, I have a vtkCanvas-derived panel, where I display some planes in 3D (actually, they are vtkImagePlaneWidgets, but I am mainly interested in the &quot;display&quot; functionality, not in the interactivity of the widget with the user). Will it be sufficient to call myVtkCanvas.GetRenderWindow().SetOffScreenRendering(1) to obtain offscreen rendering on my Mac? Or it is more complicated than that?</div>



<div><br></div><div>Currently, calling just myVtkCanvas.GetRenderWindow().SetOffScreenRendering(1), I am obtaining a crash in the OpenGL library when running my application on the Mac.</div><div><br></div><div>Thanks in advance for your feedback.</div>



<div><br></div><div>Best regards,</div><div><br></div><div>Marco</div><div><br></div></div>
<br>_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the VTK FAQ at: <a href="http://www.vtk.org/Wiki/VTK_FAQ" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.vtk.org/mailman/listinfo/vtkusers" target="_blank">http://www.vtk.org/mailman/listinfo/vtkusers</a><br>
<br></blockquote></div><br></div>
</blockquote></div><br></div>
</div></div></blockquote></div><br></div>