On Sat, Aug 08, 2009 at 10:32:16AM +0200, Uwe Hoffmann wrote: > i'm trying to incorporate two independent mayavi "controls" ( yet not > sure about the right terminology) into an wxpython application. > I'm using mayavi3.3 , python2.6.2, wx 2.8.9.1 on ubuntu.
> My starting point is the wx_mayavi_embed_in_notebook.py example. > When I start the application many > (python:5836): Gdk-WARNING **: > /build/buildd/gtk+2.0-2.16.1/gdk/x11/gdkdrawable-x11.c: > 878 drawable is not a pixmap or window > show up. > Afterwards i get an errormessage: > Traceback (most recent call last): > File > "/usr/local/lib/python2.6/dist-packages/Mayavi-3.3.0-py2.6-linux-x86_64.egg/enthought/tvtk/pyface/ui/wx/scene.py", > line 530, in OnPaint > self.light_manager = light_manager.LightManager(self) > File > "/usr/local/lib/python2.6/dist-packages/Mayavi-3.3.0-py2.6-linux-x86_64.egg/enthought/tvtk/pyface/light_manager.py", > line 347, in __init__ > ren.lights[0].intensity = 0.0 > File "tvtk_classes/collection.py", line 196, in __getitem__ > IndexError: Index out of range. > The dialog is still shown but the second tab only shows the mayavi > "toolbar" without an object. Sorry that we managed to shoot a release out letting this bug slip. There are two problems here, one that is created the traceback that you point out. I have fixed this one in SVN, but it is quite harmless, as far as you are concerned. The other one, is that the objects are added to the wrong scene, when the second MayaviView object is created. I have fixed this example to take this in account (you will need the Mayavi at least 3.3 to make use of the fix). You can see the fixed example on https://svn.enthought.com/enthought/browser/Mayavi/trunk/examples/mayavi/interactive/wx_mayavi_embed_in_notebook.py I believe this example should work on your box, producing the traceback that you point out, but that shouldn't be a problem. Now I need to figure out why the objects are now added to the wrong scene, whereas they used to be added to the right one. Thanks for your report, Gaƫl ------------------------------------------------------------------------------ Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ MayaVi-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/mayavi-users
