main.cpp 414 B

12345678910111213141516
  1. #include "FeedLevelDetector.h"
  2. #include <iostream>
  3. int main(int argc, char** argv) {
  4. if (argc != 2) {
  5. std::cerr << "Usage: " << argv[0] << " <image_path>" << std::endl;
  6. return -1;
  7. }
  8. FeedLevelDetector detector;
  9. float distance = detector.detectFeedLevel(argv[1]);
  10. std::cout << "Feed level distance from top: " << distance << " pixels" << std::endl;
  11. return 0;
  12. }