| 1 |
#ifndef CVD_INCLUDE_VISION_EXCEPTIONS_H |
| 2 |
#define CVD_INCLUDE_VISION_EXCEPTIONS_H |
| 3 |
|
| 4 |
#include <cvd/exceptions.h> |
| 5 |
#include <string> |
| 6 |
|
| 7 |
namespace CVD |
| 8 |
{ |
| 9 |
|
| 10 |
namespace Exceptions |
| 11 |
{ |
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
namespace Vision |
| 16 |
{ |
| 17 |
|
| 18 |
|
| 19 |
struct All : public CVD::Exceptions::All |
| 20 |
{ |
| 21 |
using CVD::Exceptions::All::All; |
| 22 |
}; |
| 23 |
|
| 24 |
|
| 25 |
|
| 26 |
struct IncompatibleImageSizes : public All |
| 27 |
{ |
| 28 |
IncompatibleImageSizes(const std::string& function) |
| 29 |
: All("Incompatible image sizes in " + function) {}; |
| 30 |
}; |
| 31 |
|
| 32 |
|
| 33 |
|
| 34 |
struct ImageRefNotInImage : public All |
| 35 |
{ |
| 36 |
ImageRefNotInImage(const std::string& function) |
| 37 |
: All("Input ImageRefs not in image in " + function) {}; |
| 38 |
}; |
| 39 |
|
| 40 |
struct BadInput : public All |
| 41 |
{ |
| 42 |
BadInput(const std::string& function) |
| 43 |
: All("Bad input in " + function) {}; |
| 44 |
}; |
| 45 |
}; |
| 46 |
} |
| 47 |
} |
| 48 |
|
| 49 |
#endif |