Abstract interface of a recording strategy.
More...
#include <VisionX/libraries/imrec/record/AbstractRecordingStrategy.h>
|
| | AbstractRecordingStrategy () |
| | Default constructor to start the recording manually.
|
| |
| | AbstractRecordingStrategy (const std::filesystem::path &filePath) |
| | Constructor for any recording strategy, immediately starting the recording.
|
| |
| virtual std::filesystem::path | getDotExtension () const |
| | Gets the extension plus preceeded dot of the configured file (e.g.
|
| |
| virtual std::filesystem::path | getFilePath () const |
| | Gets the raw file path for the recording as configured.
|
| |
| virtual std::filesystem::path | getMetadataPath () const |
| |
| virtual std::filesystem::path | getPath () const |
| | Gets the path to the recording without filename.
|
| |
| virtual std::filesystem::path | getStem () const |
| | Gets the stem of the configured file (filename without extension)
|
| |
| virtual bool | isRecording () const |
| | Indicates whether this instance is already initialised for recording.
|
| |
| virtual void | recordFrame (const CByteImage &frame, std::chrono::microseconds timestamp) |
| | Adds the given frame to the recording.
|
| |
| virtual void | recordFrame (const cv::Mat &frame, std::chrono::microseconds timestamp) |
| | Adds the given frame to the recording.
|
| |
| virtual void | startRecording () |
| | Starts the recording manually if constructed empty.
|
| |
| virtual void | stopRecording () |
| | Stops the recording.
|
| |
| virtual void | writeMetadataDatetime (const std::string &var_name, std::chrono::microseconds timestamp) |
| |
| virtual std::tuple< unsigned int, std::string > | writeMetadataFrame (const CByteImage &frame, std::chrono::microseconds timestamp) |
| |
| virtual std::tuple< unsigned int, std::string > | writeMetadataFrame (const cv::Mat &frame, std::chrono::microseconds timestamp) |
| |
| virtual void | writeMetadataLine (const std::string &var_name, std::string_view var_type, std::string_view var_value) |
| |
| virtual | ~AbstractRecordingStrategy () |
| | Destructor.
|
| |
|
| std::filesystem::path | m_file_path |
| | Path to where the recording file should be written to.
|
| |
Abstract interface of a recording strategy.
◆ AbstractRecordingStrategy() [1/2]
Default constructor to start the recording manually.
◆ AbstractRecordingStrategy() [2/2]
Constructor for any recording strategy, immediately starting the recording.
- Parameters
-
| filePath | Path to where the recording file should be written to |
| fps | Amount of frames being recorded per second |
◆ ~AbstractRecordingStrategy()
◆ getDotExtension()
| std::filesystem::path getDotExtension |
( |
| ) |
const |
|
virtual |
Gets the extension plus preceeded dot of the configured file (e.g.
".avi")
- Returns
- Extention plus preceeded dot of the configured file
Reimplemented in AbstractSequencedRecordingStrategy.
◆ getFilePath()
| std::filesystem::path getFilePath |
( |
| ) |
const |
|
virtual |
Gets the raw file path for the recording as configured.
- Returns
- Raw file path for the recording as configureds
◆ getMetadataPath()
| std::filesystem::path getMetadataPath |
( |
| ) |
const |
|
virtual |
◆ getPath()
| std::filesystem::path getPath |
( |
| ) |
const |
|
virtual |
Gets the path to the recording without filename.
- Returns
- Path to the recording without filename
◆ getStem()
| std::filesystem::path getStem |
( |
| ) |
const |
|
virtual |
Gets the stem of the configured file (filename without extension)
- Returns
- Stem of the configured file
◆ isRecording()
| bool isRecording |
( |
| ) |
const |
|
virtual |
Indicates whether this instance is already initialised for recording.
- Returns
- True if it is initialised and ready to record, false if not
◆ recordFrame() [1/2]
| void recordFrame |
( |
const CByteImage & | frame, |
|
|
std::chrono::microseconds | timestamp ) |
|
virtual |
◆ recordFrame() [2/2]
| void recordFrame |
( |
const cv::Mat & | frame, |
|
|
std::chrono::microseconds | timestamp ) |
|
virtual |
◆ startRecording()
◆ stopRecording()
◆ writeMetadataDatetime()
| void writeMetadataDatetime |
( |
const std::string & | var_name, |
|
|
std::chrono::microseconds | timestamp ) |
|
virtual |
◆ writeMetadataFrame() [1/2]
| std::tuple< unsigned int, std::string > writeMetadataFrame |
( |
const CByteImage & | frame, |
|
|
std::chrono::microseconds | timestamp ) |
|
virtual |
◆ writeMetadataFrame() [2/2]
| std::tuple< unsigned int, std::string > writeMetadataFrame |
( |
const cv::Mat & | frame, |
|
|
std::chrono::microseconds | timestamp ) |
|
virtual |
◆ writeMetadataLine()
| void writeMetadataLine |
( |
const std::string & | var_name, |
|
|
std::string_view | var_type, |
|
|
std::string_view | var_value ) |
|
virtual |
◆ m_file_path
| std::filesystem::path m_file_path |
|
protected |
Path to where the recording file should be written to.
The documentation for this class was generated from the following files: