// test_segm.cc - Test la segmentation // robert - Programme du robot APBteam // Copyright (C) 2005 Olivier Gaillard #include #include "imgInterface.hh" #include "segmLearn.hh" #include "oconfig.hh" int main(int argc, char **argv) { // Usage if (argc < 2) { std::cout << "Usage : test_segm " << std::endl; return 1; } // Initialisation des classes OConfig oconfig_; ImgInterface img; img.loadRaw (argv[1], Image::rgb, 360, 296); SegmLearn segm; segm.buildNN (oconfig_.nnNbColor, Segm::loadFromFile); segm.showNodes (); segm.segmImg (&img); // Création de l'image segmentée img.doImg (); img.writeRaw ("../runtime/shots/segm.rgb", img.getTabOut ()); }