13#ifndef OPENSHOT_EXCEPTIONS_H
14#define OPENSHOT_EXCEPTIONS_H
34 virtual const char*
what() const noexcept {
278 (
json.size() > 100 ?
" (abbreviated): " :
": ")
279 +
json.substr(0, 99);
318 +
" Max frames: " + std::to_string(
MaxFrames));
342 +
" Max point: " + std::to_string(
MaxPoints));
392#define TMS_DEP_MSG "The library no longer throws this exception. It will be removed in a future release."
Exception when a required chunk is missing.
ChunkNotFound(std::string message, int64_t frame_number, int64_t chunk_number, int64_t chunk_frame)
Constructor.
virtual ~ChunkNotFound() noexcept
Exception when accessing a blackmagic decklink card.
DecklinkError(std::string message)
Constructor.
virtual ~DecklinkError() noexcept
Exception when decoding audio packet.
virtual ~ErrorDecodingAudio() noexcept
ErrorDecodingAudio(std::string message, int64_t frame_number=-1)
Constructor.
Exception when encoding audio packet.
ErrorEncodingAudio(std::string message, int64_t frame_number=-1)
Constructor.
virtual ~ErrorEncodingAudio() noexcept
Exception when encoding audio packet.
virtual ~ErrorEncodingVideo() noexcept
ErrorEncodingVideo(std::string message, int64_t frame_number=-1)
Constructor.
Base exception class with a custom message variable.
virtual ~ExceptionBase() noexcept
virtual std::string py_message() const
ExceptionBase(std::string message)
virtual const char * what() const noexcept
FileExceptionBase(std::string message, std::string file_path="")
virtual std::string py_message() const override
FrameExceptionBase(std::string message, int64_t frame_number=-1)
virtual std::string py_message() const override
Exception when an invalid # of audio channels are detected.
InvalidChannels(std::string message, std::string file_path="")
Constructor.
virtual ~InvalidChannels() noexcept
Exception when no valid codec is found for a file.
InvalidCodec(std::string message, std::string file_path="")
Constructor.
virtual ~InvalidCodec() noexcept
Exception for files that can not be found or opened.
InvalidFile(std::string message, std::string file_path)
Constructor.
virtual ~InvalidFile() noexcept
Exception for missing JSON Change key.
std::string py_message() const override
virtual ~InvalidJSONKey() noexcept
InvalidJSONKey(std::string message, std::string json)
Constructor.
Exception for invalid JSON.
virtual ~InvalidJSON() noexcept
InvalidJSON(std::string message, std::string file_path="")
Constructor.
Exception when invalid encoding options are used.
InvalidOptions(std::string message, std::string file_path="")
Constructor.
virtual ~InvalidOptions() noexcept
Exception when invalid sample rate is detected during encoding.
virtual ~InvalidSampleRate() noexcept
InvalidSampleRate(std::string message, std::string file_path="")
Constructor.
Exception when no streams are found in the file.
NoStreamsFound(std::string message, std::string file_path="")
Constructor.
virtual ~NoStreamsFound() noexcept
Exception for frames that are out of bounds.
OutOfBoundsFrame(std::string message, int64_t frame_requested, int64_t max_frames)
Constructor.
virtual ~OutOfBoundsFrame() noexcept
std::string py_message() const override
Exception for an out of bounds key-frame point.
std::string py_message() const override
virtual ~OutOfBoundsPoint() noexcept
OutOfBoundsPoint(std::string message, int point_requested, int max_points)
Constructor.
Exception when memory could not be allocated.
virtual ~OutOfMemory() noexcept
OutOfMemory(std::string message, std::string file_path="")
Constructor.
Exception when a reader is closed, and a frame is requested.
virtual ~ReaderClosed() noexcept
ReaderClosed(std::string message, std::string file_path="")
Constructor.
Exception when resample fails.
virtual ~ResampleError() noexcept
ResampleError(std::string message, std::string file_path="")
Constructor.
Exception when too many seek attempts happen.
virtual ~TooManySeeks() noexcept
TooManySeeks(std::string message, std::string file_path="")
Constructor.
Exception when a writer is closed, and a frame is requested.
WriterClosed(std::string message, std::string file_path="")
Constructor.
virtual ~WriterClosed() noexcept
This namespace is the default namespace for all code in the openshot library.