VTK
vtkWin32VideoSource.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkWin32VideoSource.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
34 #ifndef vtkWin32VideoSource_h
35 #define vtkWin32VideoSource_h
36 
37 #include "vtkIOVideoModule.h" // For export macro
38 #include "vtkVideoSource.h"
39 
40 class vtkWin32VideoSourceInternal;
41 
42 class VTKIOVIDEO_EXPORT vtkWin32VideoSource : public vtkVideoSource
43 {
44 public:
47  void PrintSelf(ostream& os, vtkIndent indent);
48 
52  void Record();
53 
57  void Play();
58 
62  void Stop();
63 
67  void Grab();
68 
70 
73  void SetFrameSize(int x, int y, int z);
74  virtual void SetFrameSize(int dim[3]) {
75  this->SetFrameSize(dim[0], dim[1], dim[2]); };
77 
81  void SetFrameRate(float rate);
82 
86  void SetOutputFormat(int format);
87 
89 
92  void SetPreview(int p);
93  vtkBooleanMacro(Preview,int);
94  vtkGetMacro(Preview,int);
96 
101 
106 
111  void Initialize();
112 
118 
120 
123  void LocalInternalGrab(void*);
126 
127 protected:
130 
131  char WndClassName[16];
133  int Preview;
134 
135  vtkWin32VideoSourceInternal *Internal;
136 
137  void CheckBuffer();
138  void UnpackRasterLine(char *outptr, char *inptr,
139  int start, int count);
140 
143 
144 private:
145  vtkWin32VideoSource(const vtkWin32VideoSource&) VTK_DELETE_FUNCTION;
146  void operator=(const vtkWin32VideoSource&) VTK_DELETE_FUNCTION;
147 };
148 
149 #endif
150 
151 
152 
153 
154 
vtkWin32VideoSource::~vtkWin32VideoSource
~vtkWin32VideoSource()
vtkWin32VideoSource::BitMapSize
int BitMapSize
Definition: vtkWin32VideoSource.h:132
vtkWin32VideoSource::vtkWin32VideoSource
vtkWin32VideoSource()
vtkWin32VideoSource::SetPreview
void SetPreview(int p)
Turn on/off the preview (overlay) window.
vtkWin32VideoSource::SetOutputFormat
void SetOutputFormat(int format)
Request a particular output format (default: VTK_RGB).
vtkVideoSource.h
vtkWin32VideoSource::SetFrameSize
virtual void SetFrameSize(int dim[3])
Definition: vtkWin32VideoSource.h:74
vtkWin32VideoSource::DoVFWFormatSetup
void DoVFWFormatSetup()
vtkWin32VideoSource::Play
void Play()
Standard VCR functionality: Play recorded video.
vtkWin32VideoSource::Record
void Record()
Standard VCR functionality: Record incoming video.
vtkWin32VideoSource::Grab
void Grab()
Grab a single video frame.
vtkWin32VideoSource::DoVFWFormatCheck
void DoVFWFormatCheck()
vtkWin32VideoSource::OnParentWndDestroy
void OnParentWndDestroy()
vtkWin32VideoSource::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent)
Methods invoked by print to print information about the object including superclasses.
vtkWin32VideoSource::UnpackRasterLine
void UnpackRasterLine(char *outptr, char *inptr, int start, int count)
vtkWin32VideoSource::SetFrameRate
void SetFrameRate(float rate)
Request a particular frame rate (default 30 frames per second).
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:40
vtkWin32VideoSource::New
static vtkWin32VideoSource * New()
vtkWin32VideoSource::Internal
vtkWin32VideoSourceInternal * Internal
Definition: vtkWin32VideoSource.h:135
vtkWin32VideoSource::Preview
int Preview
Definition: vtkWin32VideoSource.h:133
vtkBooleanMacro
vtkBooleanMacro(IgnoreDriverBugs, bool)
Updates the extensions string.
vtkVideoSource::SetFrameSize
virtual void SetFrameSize(int x, int y, int z)
Set the full-frame size.
vtkWin32VideoSource
Video-for-Windows video digitizer.
Definition: vtkWin32VideoSource.h:43
vtkWin32VideoSource::VideoSourceDialog
void VideoSourceDialog()
Bring up a modal dialog box for video input selection.
vtkWin32VideoSource::CheckBuffer
void CheckBuffer()
vtkWin32VideoSource::LocalInternalGrab
void LocalInternalGrab(void *)
For internal use only.
vtkWin32VideoSource::Stop
void Stop()
Standard VCR functionality: Stop recording or playing.
vtkWin32VideoSource::VideoFormatDialog
void VideoFormatDialog()
Bring up a modal dialog box for video format selection.
vtkWin32VideoSource::ReleaseSystemResources
void ReleaseSystemResources()
Free the driver (this is called automatically inside the destructor).
vtkWin32VideoSource::Initialize
void Initialize()
Initialize the driver (this is called automatically when the first grab is done).
vtkWin32VideoSource::SetFrameSize
void SetFrameSize(int x, int y, int z)
Request a particular frame size (set the third value to 1).
vtkVideoSource
Superclass of video input devices for VTK.
Definition: vtkVideoSource.h:44