 |
VTK
9.0.1
|
Go to the documentation of this file.
27 #ifndef vtkFFMPEGVideoSource_h
28 #define vtkFFMPEGVideoSource_h
30 #include "vtkIOFFMPEGModule.h"
36 class vtkFFMPEGVideoSourceInternal;
128 vtkSetStringMacro(FileName);
129 vtkGetStringMacro(FileName);
141 vtkGetMacro(EndOfFile,
bool);
144 vtkGetMacro(Stereo3D,
bool);
156 this->AudioCallback = cb;
157 this->AudioCallbackClientData = clientData;
169 this->VideoCallback = cb;
170 this->VideoCallbackClientData = clientData;
179 vtkSetMacro(DecodingThreads,
int);
180 vtkGetMacro(DecodingThreads,
int);
void * DrainAudio(vtkMultiThreader::ThreadInfo *data)
std::function< void(vtkFFMPEGVideoSourceVideoCallbackData const &data)> VideoCallbackType
VideoCallbackType VideoCallback
vtkNew< vtkMutexLock > FeedMutex
void * Drain(vtkMultiThreader::ThreadInfo *data)
mutual exclusion locking class
void SetFrameSize(int dim[3]) override
Reader for ffmpeg supported formats.
void SetVideoCallback(VideoCallbackType cb, void *clientData)
void * AudioCallbackClientData
vtkNew< vtkConditionVariable > FeedCondition
This is the structure that is passed to the thread that is created from the SingleMethodExecute,...
void SetFrameRate(float rate) override
Request a particular frame rate (default 30 frames per second).
static void * DrainAudioThread(vtkMultiThreader::ThreadInfo *data)
void Record() override
Standard VCR functionality: Record incoming video.
std::function< void(vtkFFMPEGVideoSourceAudioCallbackData const &data)> AudioCallbackType
void Stop() override
Standard VCR functionality: Stop recording or playing.
void * Feed(vtkMultiThreader::ThreadInfo *data)
void Play() override
Standard VCR functionality: Play recorded video.
vtkFFMPEGVideoSource * Caller
void ReleaseSystemResources() override
Free the driver (this is called automatically inside the destructor).
void Grab() override
Grab a single video frame.
~vtkFFMPEGVideoSource() override
vtkFFMPEGVideoSource * Caller
void InternalGrab() override
The internal function which actually does the grab.
void SetFrameSize(int x, int y, int z) override
Request a particular frame size (set the third value to 1).
static vtkFFMPEGVideoSource * New()
void SetOutputFormat(int format) override
Request a particular output format (default: VTK_RGB).
void Initialize() override
Initialize the driver (this is called automatically when the first grab is done).
mutual exclusion locking class
void * VideoCallbackClientData
static void * FeedThread(vtkMultiThreader::ThreadInfo *data)
static void * DrainThread(vtkMultiThreader::ThreadInfo *data)
vtkNew< vtkMutexLock > FeedAudioMutex
AudioCallbackType AudioCallback
void SetAudioCallback(AudioCallbackType cb, void *clientData)
vtkNew< vtkConditionVariable > FeedAudioCondition
vtkFFMPEGVideoSourceInternal * Internal
Superclass of video input devices for VTK.