<div>Hi Lars,</div>
<div> </div>
<div>sorry for the late reply. Thanks a lot! I just tried this out. It does seem to not open the X Window, but I still need a X connection, otherwise my code terminates when it calls the GetDesiredVisualInfo() method. For my purposes I would need a VTK based rendering service that I can interact with remotely (starting it from a SSH terminal, sending rendered data to a client through a socket etc.). I will look into this some more. I wonder if I can hardcode all the information that the render window needs and tries to retrieve from the display.</div>

<div> </div>
<div>Thanks again!</div>
<div> </div>
<div>Mark </div>
<div><br><br> </div>
<div class="gmail_quote">2010/10/3 Lars Friedrich Lars <span dir="ltr">&lt;<a href="mailto:lars-friedrich@gmx.net">lars-friedrich@gmx.net</a>&gt;</span><br>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">Hello Mark,<br><br><br>I&#39;m having a comparable problem. I found a solution that works for me, maybe this is also a solution to your situation ...<br>
<br>Basically, I want to hide the X-window when using GL hardware off-screen rendering. My first experiments involved XUnmapWindow - however, as the X window is initially mapped in the CreateAWindow()-method, the window will appear at least for a few milliseconds prior to calling XUnmapWindow(). This is neither &quot;nice&quot;, nor a solution to your problem.<br>
<br>Therefore, I inherited from vtkXOpenGLRenderWindow and overrode the CreateAWindow()-method. I simply eliminated the code block that calls XMapWindow() initially -&gt; the off-screen window never gets mapped ...<br><br>
The inherited class is however suboptimal, as I had to redefine the vtkXOpenGLRenderWindowInternal class (forward declaration ...).<br><br>I attachted a simple example (hidex.cxx) that makes use of the simple inherited class. If you want, try it, and please let me know whether or not it works for you.<br>
<br><br>regards,<br><br>lars<br><br><br><br><br>-------- Original-Nachricht --------<br>&gt; Datum: Thu, 23 Sep 2010 10:54:54 -0400<br>&gt; Von: Aashish Chaudhary &lt;<a href="mailto:aashish.chaudhary@kitware.com">aashish.chaudhary@kitware.com</a>&gt;<br>
&gt; An: endlosschleife1 &lt;<a href="mailto:endlosschleife1@googlemail.com">endlosschleife1@googlemail.com</a>&gt;<br>&gt; CC: <a href="mailto:vtkusers@vtk.org">vtkusers@vtk.org</a><br>&gt; Betreff: Re: [vtkusers] Offscreen Rendering &amp; Linux<br>
<br>&gt; Mark,<br>&gt;<br>&gt; I believe that as of now if you want to use OpenGL driver and not Mesa it<br>&gt; requires opening an windows or else you have to use Mesa (like you did).<br>&gt; There is no workaround for the former case.<br>
&gt;<br>&gt; On Thu, Sep 23, 2010 at 6:48 AM, endlosschleife1 &lt;<br>&gt; <a href="mailto:endlosschleife1@googlemail.com">endlosschleife1@googlemail.com</a>&gt; wrote:<br>&gt;<br>&gt; &gt; Hello,<br>&gt; &gt;<br>&gt; &gt; has anybody some experience with doing offscreen rendering under Linux<br>
&gt; with<br>&gt; &gt; graphics acceleration support and give me some hints on how to get this<br>&gt; to<br>&gt; &gt; work?<br>&gt; &gt;<br>&gt; &gt; I&#39;m using a vtkOpenGLRenderWindow and set OffScreenRendering to on. With<br>
&gt; &gt; that it does really not render into a window, but VTK still opens an X<br>&gt; &gt; Window (apparently it needs its handle). So for instance when I try to<br>&gt; start<br>&gt; &gt; a VTK based app remotely via SSH I get the following error message:<br>
&gt; &gt;<br>&gt; &gt; # An unexpected error has been detected by Java Runtime Environment:<br>&gt; &gt; #<br>&gt; &gt; #  SIGSEGV (0xb) at pc=0xb2b5b4f5, pid=16472, tid=3044047776<br>&gt; &gt; #<br>&gt; &gt; # Java VM: Java HotSpot(TM) Client VM (1.6.0-b105 mixed mode, sharing)<br>
&gt; &gt; # Problematic frame:<br>&gt; &gt; # C  [libvtkRenderingJava.so.5.6.0+0x66c4f5]<br>&gt; &gt; _ZN22vtkXOpenGLRenderWindow13CreateAWindowEv+0x37b<br>&gt; &gt; #<br>&gt; &gt; # An error report file with more information is saved as<br>
&gt; &gt; hs_err_pid16472.log<br>&gt; &gt; #<br>&gt; &gt; # If you would like to submit a bug report, please visit:<br>&gt; &gt; #   <a href="http://java.sun.com/webapps/bugreport/crash.jsp" target="_blank">http://java.sun.com/webapps/bugreport/crash.jsp</a><br>
&gt; &gt; #<br>&gt; &gt;<br>&gt; &gt; Is there any way around the need for VTK to open an X window? Basically<br>&gt; I<br>&gt; &gt; would like to know if that problem is even fixable or if I need to look<br>&gt; for<br>&gt; &gt; other workarounds.<br>
&gt; &gt;<br>&gt; &gt; When I build VTK with MESA enabled it works, but the performance without<br>&gt; &gt; accelaration is unacceptable.<br>&gt; &gt;<br>&gt; &gt; Thanks,<br>&gt; &gt; Mark<br>&gt; &gt; _______________________________________________<br>
&gt; &gt; Powered by <a href="http://www.kitware.com/" target="_blank">www.kitware.com</a><br>&gt; &gt;<br>&gt; &gt; Visit other Kitware open-source projects at<br>&gt; &gt; <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
&gt; &gt;<br>&gt; &gt; Please keep messages on-topic and check the VTK FAQ at:<br>&gt; &gt; <a href="http://www.vtk.org/Wiki/VTK_FAQ" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>&gt; &gt;<br>&gt; &gt; Follow this link to subscribe/unsubscribe:<br>
&gt; &gt; <a href="http://www.vtk.org/mailman/listinfo/vtkusers" target="_blank">http://www.vtk.org/mailman/listinfo/vtkusers</a><br>&gt; &gt;<br>&gt; &gt;<br>&gt;<br>&gt;<br>&gt; --<br>&gt; | Aashish Chaudhary<br>&gt; | R&amp;D Engineer<br>
&gt; | Kitware Inc.<br>&gt; | <a href="http://www.kitware.com/" target="_blank">www.kitware.com</a><br><font color="#888888"><br>--<br>GRATIS: Spider-Man 1-3 sowie 300 weitere Videos!<br>Jetzt freischalten! <a href="http://portal.gmx.net/de/go/maxdome" target="_blank">http://portal.gmx.net/de/go/maxdome</a><br>
</font></blockquote></div><br>