Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members   Related Pages  

Hybrid/vtkWin32VideoSource.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    $RCSfile: vtkWin32VideoSource.h,v $
00005   Language:  C++
00006 
00007   Copyright (c) 1993-2002 Ken Martin, Will Schroeder, Bill Lorensen 
00008   All rights reserved.
00009   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
00010 
00011      This software is distributed WITHOUT ANY WARRANTY; without even 
00012      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
00013      PURPOSE.  See the above copyright notice for more information.
00014 
00015 =========================================================================*/
00048 #ifndef __vtkWin32VideoSource_h
00049 #define __vtkWin32VideoSource_h
00050 
00051 #include "vtkVideoSource.h"
00052 
00053 class vtkWin32VideoSourceInternal;
00054 
00055 class VTK_HYBRID_EXPORT vtkWin32VideoSource : public vtkVideoSource
00056 {
00057 public:
00058   static vtkWin32VideoSource *New();
00059   vtkTypeRevisionMacro(vtkWin32VideoSource,vtkVideoSource);
00060   void PrintSelf(ostream& os, vtkIndent indent);   
00061 
00063   void Record();
00064 
00066   void Play();
00067 
00069   void Stop();
00070 
00072   void Grab();
00073  
00075   void SetFrameSize(int x, int y, int z);
00076   
00078   void SetFrameRate(float rate);
00079 
00081   void SetOutputFormat(int format);
00082 
00084 
00085   void SetPreview(int p);
00086   vtkBooleanMacro(Preview,int);
00087   vtkGetMacro(Preview,int);
00089 
00091   void VideoFormatDialog();
00092 
00094   void VideoSourceDialog();
00095 
00098   void Initialize();
00099 
00101   void ReleaseSystemResources();
00102 
00104 
00105   void InternalGrab(void*);
00106   void OnParentWndDestroy();
00108 
00109 protected:
00110   vtkWin32VideoSource();
00111   ~vtkWin32VideoSource();
00112 
00113   char WndClassName[16];
00114   int BitMapSize;
00115   int Preview;
00116 
00117   vtkWin32VideoSourceInternal *Internal;
00118 
00119   void CheckBuffer();
00120   void UnpackRasterLine(char *outptr, char *inptr, 
00121                         int start, int count);
00122 
00123   void DoVFWFormatSetup();
00124   void DoVFWFormatCheck();
00125 
00126 private:
00127   vtkWin32VideoSource(const vtkWin32VideoSource&);  // Not implemented.
00128   void operator=(const vtkWin32VideoSource&);  // Not implemented.
00129 };
00130 
00131 #endif
00132 
00133 
00134 
00135 
00136