/*! * Takes ownership of the labyrinth \p lab. */ void LabyrinthWidget::set_labyrinth( Labyrinth* lab ) { if( lab_ == lab ) { return; } delete lab_; lab_ = lab; fill_scene(); }
t_scene *get_scene(char *path) { t_node *root; t_scene *sc; char *xml; xml = parser(path); if (xml != NULL) { root = NULL; sc = xmalloc(sizeof(*sc)); my_putstr("Parsing: \t\tOK"); add_node(&root, "root", xml); my_putstr("Adding node root: \tOK"); build_tree(&root); my_putstr("Building tree: \t\tOK"); fill_scene(&sc, root); my_putstr("Fill_scene: \t\tOK"); free(xml); return (sc); } return (NULL); }