def initialize(self): from openalea.core.world.world import World from openalea.core.service.ipython import interpreter world = World() world.update_namespace(interpreter()) self.set_world(world)
def initialize(self): from openalea.core.world.world import World from openalea.core.service.ipython import interpreter world = World() world.update_namespace(interpreter()) self.set_world(world) set_default_control(self._controls, 'img_filename') set_default_control(self._controls, 'cell_vertex_filename') # set_default_control(self._controls,'triangulation_filename') set_default_control(self._controls, 'initialize') self._fill_manager() self._set_manager(self._manager)
def main(): import sys app = QtGui.QApplication(sys.argv) from openalea.core.world import World world = World() world["obj1"] = "plop" world["obj2"] = "plop2" obj1 = world["obj1"] obj2 = world["obj2"] obj1.set_attribute('a1', 1, 'IInt') obj1.set_attribute('a2', True, 'IBool') obj2.set_attribute('b1', 2.34, 'IFloat') wid1 = WorldControlPanel(style=WorldControlPanel.StylePanel) wid1.set_world(world) wid1.show() wid2 = WorldControlPanel(style=WorldControlPanel.StyleTableView) wid2.set_world(world) wid2.show() app.exec_()
def initialize(self): from openalea.core.world.world import World from openalea.core.service.ipython import interpreter world = World() world.update_namespace(interpreter()) self.set_world(world) set_default_control(self._controls,'img_filename') set_default_control(self._controls,'cell_vertex_filename') # set_default_control(self._controls,'triangulation_filename') set_default_control(self._controls,'initialize') self._fill_manager() self._set_manager(self._manager)
def __init__(self, inputs, outputs): Node.__init__(self, inputs, outputs) self.world = World()
def test_run_all(controllers): interp.user_ns['world'] = World() interp.user_ns['lst'] = [1, 2, 1, 3, 1, 4] for i, controller in enumerate(controllers): controller.run() return True
def initialize(self): from openalea.core.world.world import World world = World() self.set_world(world)