| 1 | #include <cvd/exceptions.h> |
| 2 | #include <cvd/videobuffer.h> |
| 3 | |
| 4 | CVD::Exceptions::OutOfMemory::OutOfMemory() |
| 5 | : CVD::Exceptions::All("Out of memory.") |
| 6 | { |
| 7 | } |
| 8 | |
| 9 | CVD::Exceptions::VideoBuffer::BadPutFrame::BadPutFrame() |
| 10 | : CVD::Exceptions::VideoBuffer::All("Attempted to put_frame() on the wrong kind of frame.") |
| 11 | { |
| 12 | } |
| 13 | |
| 14 | CVD::Exceptions::VideoBuffer::BadColourSpace::BadColourSpace(const std::string& c, const std::string& buffer) |
| 15 | : CVD::Exceptions::VideoBuffer::All( |
| 16 | buffer + " can not grab video in the " + c + "colourspace on the specified device.") |
| 17 | { |
| 18 | } |
| 19 | |
| 20 | [[noreturn]] void CVD::Internal::error_abort(const char* f, int l, const char* code) |
| 21 | { |
| 22 | std::cerr << "Assertion failed at " << f << ": " << l << " " << code << "\n"; |
| 23 | std::abort(); |
| 24 | } |