RSSlic.h 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. /**
  2. * @file RSSlic.h
  3. * @brief SLIC Superpixels from "SLIC Superpixels Compared to State-of-the-art Superpixel Methods,"
  4. * @author Björn Fröhlich
  5. * @date 02/02/2013
  6. */
  7. #ifndef RSSlicINCLUDE
  8. #define RSSlicINCLUDE
  9. #include "core/basics/Config.h"
  10. #include "RegionSegmentationMethod.h"
  11. namespace OBJREC {
  12. class RSSlic: public RegionSegmentationMethod
  13. {
  14. protected:
  15. int spcount; //number of regions
  16. double compactness; //value between 0 and 40
  17. public:
  18. /** simple constructor */
  19. RSSlic();
  20. /** simple constructor */
  21. RSSlic(double t);
  22. /**
  23. * standard constructor
  24. * @param conf config file
  25. */
  26. RSSlic(const NICE::Config *conf );
  27. /** simple destructor */
  28. ~RSSlic();
  29. /**
  30. * returns the regions of a given image
  31. * @param img input image
  32. * @param mask output regions, each region has it own number
  33. * @return count of region
  34. */
  35. virtual int segRegions ( const NICE::Image & img, NICE::Matrix & mask ) const;
  36. /**
  37. * returns the regions of a given image
  38. * @param img input color image
  39. * @param mask output regions, each region has it own number
  40. * @return count of region
  41. */
  42. virtual int segRegions ( const NICE::ColorImage & img, NICE::Matrix & mask) const;
  43. };
  44. } //namespace
  45. #endif