CustusX
15.3.3-beta
An IGT application
|
#include <cxSavingVideoRecorder.h>
Classes | |
struct | DataType |
Public Member Functions | |
VideoRecorderSaveThread (QObject *parent, QString saveFolder, QString prefix, bool compressed, bool writeColor) | |
virtual | ~VideoRecorderSaveThread () |
QString | addData (double timestamp, vtkImageDataPtr data) |
void | stop () |
void | cancel () |
Protected Member Functions | |
virtual void | run () |
void | writeQueue () |
bool | openTimestampsFile () |
bool | closeTimestampsFile () |
void | write (DataType data) |
Protected Attributes | |
QString | mSaveFolder |
QString | mPrefix |
int | mImageIndex |
std::list< DataType > | mPendingData |
QMutex | mMutex |
protects the mPendingData More... | |
bool | mStop |
bool | mCancel |
QFile | mTimestampsFile |
bool | mCompressed |
bool | mWriteColor |
Class that saves vtkImageData continously to file.
The data are saved as separate files in the saveSolder, using prefix as a common filename component:
A single file named <prefix>.fts containing N lines with timestamps is written. A sequence of N files named <prefix>_i.mhd (0<i<N) and corresponding .raw files are written.
If stop() is called, the thread will continue to write all remaining data, then close files and return from run().
Note: quit() will not work on this thread, use stop() instead.
Definition at line 68 of file cxSavingVideoRecorder.h.
cx::VideoRecorderSaveThread::VideoRecorderSaveThread | ( | QObject * | parent, |
QString | saveFolder, | ||
QString | prefix, | ||
bool | compressed, | ||
bool | writeColor | ||
) |
Create the thread object, set folder to save to.
Definition at line 56 of file cxSavingVideoRecorder.cpp.
|
virtual |
Definition at line 71 of file cxSavingVideoRecorder.cpp.
QString cx::VideoRecorderSaveThread::addData | ( | double | timestamp, |
vtkImageDataPtr | data | ||
) |
Add data to be saved.
Definition at line 75 of file cxSavingVideoRecorder.cpp.
void cx::VideoRecorderSaveThread::cancel | ( | ) |
Definition at line 99 of file cxSavingVideoRecorder.cpp.
|
protected |
Definition at line 116 of file cxSavingVideoRecorder.cpp.
|
protected |
Definition at line 105 of file cxSavingVideoRecorder.cpp.
|
protectedvirtual |
Save the images to disk
Definition at line 177 of file cxSavingVideoRecorder.cpp.
void cx::VideoRecorderSaveThread::stop | ( | ) |
Definition at line 94 of file cxSavingVideoRecorder.cpp.
|
protected |
Definition at line 130 of file cxSavingVideoRecorder.cpp.
|
protected |
Write all pending images to file.
Definition at line 158 of file cxSavingVideoRecorder.cpp.
|
protected |
Definition at line 97 of file cxSavingVideoRecorder.h.
|
protected |
Definition at line 99 of file cxSavingVideoRecorder.h.
|
protected |
Definition at line 93 of file cxSavingVideoRecorder.h.
|
protected |
protects the mPendingData
Definition at line 95 of file cxSavingVideoRecorder.h.
|
protected |
Definition at line 94 of file cxSavingVideoRecorder.h.
|
protected |
Definition at line 92 of file cxSavingVideoRecorder.h.
|
protected |
Definition at line 91 of file cxSavingVideoRecorder.h.
|
protected |
Definition at line 96 of file cxSavingVideoRecorder.h.
|
protected |
Definition at line 98 of file cxSavingVideoRecorder.h.
|
protected |
Definition at line 100 of file cxSavingVideoRecorder.h.