-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Extra rendering view created for each button #40
Comments
Sorry I accidentally delete the previous comment. I wrote that it happens also on mac osx: It's a problem with VTK offscreen rendering (on linux and osx) that doesn't work properly and shows the rendering window so i think it's a VTK issue. |
You need to build VTK with VTK_OPENGL_HAS_OSMESA on. |
I build VTK with VTK_OPENGL_HAS_OSMESA enabled on Ubuntu but vtkButtons application doesn't work properly: if I load a data the surface and the button are not shown in the rendering window; It seems that offscreen rendering is used for all rendering processes. could you tell me if the application built with osmesa works correctly for you? Now I'm trying to build it with mangled mesa http://www.vtk.org/Wiki/VTK/OpenGL#OpenGL_.2B_Off_screen If I build without osmesa the application works properly and the image is shown in the tooltip (but the extra window is created) |
You are right, VTK_OPENGL_HAS_OSMESA doesn't work. Can you try to change the line vtkXOpenGLRenderWindow.cxx:642
into
Btw, I never manage to get any image in the tooltip, what type of file do you load ? |
Thank you! With your fix it works and the extra window is not shown under ubuntu. To answer your question: I get the image as a QImage from msvQVTKButtons https://github.com/MSV-Project/MSVTK/blob/master/Applications/VTKButtons/msvQVTKButtonsMainWindow.cxx#L272 then I write it in a QBuffer with PNG format and I put it in the tooltip with html code https://github.com/MSV-Project/MSVTK/blob/master/Applications/VTKButtons/msvQVTKButtonsMainWindow.cxx#L278 |
Can you then push the fix in the MSVTK fork of VTK: I managed to get the preview show up in the tooltip on my ubuntu computer. I did it by building against a Qt 4.7.3, which means that this feature is broken for Qt 4.6.3 (it was displaying a "file" icon instead of the preview). Concerning the conversion to base64, you can use |
Ok. Could you please give me write access to the forked VTK repository? |
Done. |
On Ubuntu 12.04.1, I build MSVTK in Release mode

a) Start vtkbuttons demo
b) Load a polydata .vtk file
-> the data is correctly loaded.
=> an extra black window (~100x100) is created in the top left corner of my desktop.
an extra window is created for each loaded dataset
The text was updated successfully, but these errors were encountered: