Projektarbeit Line Following Robot bei Prof. Chowanetz im WS22/23
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

input.cpp 456B

12345678910111213141516171819202122232425262728
  1. #include "input.h"
  2. Input::Input(/* args */)
  3. {
  4. }
  5. Input::~Input()
  6. {
  7. }
  8. Mat Input::readFile(String filePath)
  9. {
  10. Mat image = imread(filePath, IMREAD_COLOR);
  11. if(image.empty())
  12. {
  13. std::cout << "Could not read the image: " << filePath << std::endl;
  14. return Mat();
  15. //To do:Exception handeling
  16. }
  17. imshow("Display window", image);
  18. waitKey(0);
  19. return image;
  20. }
  21. void Input::readWebcam()
  22. {
  23. //To do an Raspberry-Pi
  24. }