On Thursday 24 February 2011 05:00 PM, David Flitney wrote:
> I want to allow the user to switch files, possibly changing the
> composition of the scene, definitely needing updated surfaces to be
> displayed. I thought the easiest solution would be to simply clear the
> scene and start again:
[...]
> self.picker =
> self.scene.mayavi_scene.on_mouse_pick(self.picker_callback)self.picker.tolerance
> = 0.001
> All is well for the first rendering of the scene: picker_callback() is
> getting called appropriately, but when I subsequently call clf(), in the
> context of update_data(), and rebuild the scene from the newly selected
> datasets my callback no longer gets called. Note the default, 'p'
> activated, picker is working.

Whoops, ignore my previous email.  It looks like clf is actually 
clearing out the mouse pick callbacks.  So after your clf call you will 
have to reset the mouse pick callback and that should do the trick for 
you.  I guess you'll just have to add the picker callback in your 
update_data method.

cheers,
Prabhu






------------------------------------------------------------------------------
Enable your software for Intel(R) Active Management Technology to meet the
growing manageability and security demands of your customers. Businesses
are taking advantage of Intel(R) vPro (TM) technology - will your software 
be a part of the solution? Download the Intel(R) Manageability Checker 
today! http://p.sf.net/sfu/intel-dev2devmar
_______________________________________________
MayaVi-users mailing list
MayaVi-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mayavi-users

Reply via email to