IGSTK
Public Attributes | Static Public Attributes | Protected Types | Protected Member Functions | List of all members
igstk::WebcamWinVideoImager Class Reference

This derivation of the VideoImager class provides communication to a Webcam in Windows. More...

#include <igstkWebcamWinVideoImager.h>

Inheritance diagram for igstk::WebcamWinVideoImager:
Inheritance graph
[legend]
Collaboration diagram for igstk::WebcamWinVideoImager:
Collaboration graph
[legend]

Public Attributes

 igstkStandardClassTraitsMacro (WebcamWinVideoImager, VideoImager) public
 Macro with standard traits declarations. More...
 
- Public Attributes inherited from igstk::VideoImager
igstkStandardAbstractClassTraitsMacro(VideoImager,
Object) public typedef
VideoImagerTool 
VideoImagerToolType
 Macro with standard traits declarations. More...
 

Static Public Attributes

static itk::MutexLock::Pointer m_FrameBufferLock
 Members and functions for communication with the webcam. More...
 

Protected Types

typedef VideoImager::ResultType ResultType
 Typedef for internal boolean return type. More...
 
- Protected Types inherited from igstk::VideoImager
enum  ResultType { FAILURE =0, SUCCESS }
 
typedef Transform::TimePeriodType TimePeriodType
 typedef for times used by the VideoImager More...
 
typedef Transform TransformType
 typedefs from Transform class More...
 
typedef Frame FrameType
 typedefs from Frame class More...
 
typedef std::map< std::string,
VideoImagerToolType * > 
VideoImagerToolsContainerType
 typedefs from VideoImagerTool class More...
 

Protected Member Functions

 WebcamWinVideoImager (void)
 
virtual ~WebcamWinVideoImager (void)
 
virtual ResultType InternalOpen (void)
 Open communication with the imaging device. More...
 
virtual ResultType InternalClose (void)
 Close communication with the imaging device. More...
 
virtual ResultType InternalStartImaging (void)
 Put the imaging device into imaging mode. More...
 
virtual ResultType InternalStopImaging (void)
 Take the imaging device out of imaging mode. More...
 
virtual ResultType InternalUpdateStatus (void)
 Update the status and the transforms for all VideoImagerTools. More...
 
virtual ResultType InternalThreadedUpdateStatus (void)
 Update the status and the frames. More...
 
virtual ResultType InternalReset (void)
 Reset the imaging device to put it back to its original state. More...
 
virtual ResultType VerifyVideoImagerToolInformation (const VideoImagerToolType *)
 Verify imager tool information. More...
 
virtual ResultType ValidateSpecifiedFrequency (double frequencyInHz)
 The "ValidateSpecifiedFrequency" method checks if the specified frequency is valid for the imaging device that is being used. More...
 
virtual void PrintSelf (std::ostream &os, itk::Indent indent) const
 Print object information. More...
 
virtual ResultType RemoveVideoImagerToolFromInternalDataContainers (const VideoImagerToolType *imagerTool)
 Remove imager tool entry from internal containers. More...
 
virtual ResultType AddVideoImagerToolToInternalDataContainers (const VideoImagerToolType *imagerTool)
 Add imager tool entry to internal containers. More...
 
- Protected Member Functions inherited from igstk::VideoImager
 VideoImager (void)
 
virtual ~VideoImager (void)
 
virtual void SetThreadingEnabled (bool _arg)
 SetThreadingEnabled(bool) : set m_ThreadingEnabled value. More...
 
virtual bool GetThreadingEnabled ()
 GetThreadingEnabled(bool) : get m_ThreadingEnabled value. More...
 
virtual TimePeriodType GetValidityTime ()
 Get the validity time. More...
 
const
VideoImagerToolsContainerType
GetVideoImagerToolContainer () const
 Access method for the VideoImager tool container. More...
 
void ReportImagingToolNotAvailable (VideoImagerToolType *VideoImagerTool) const
 Report to VideoImager tool that it is not available for imaging. More...
 
void ReportImagingToolStreaming (VideoImagerToolType *videoImagerTool) const
 Report to VideoImager tool that it is streaming. More...
 
void SetVideoImagerToolFrame (VideoImagerToolType *videoImagerTool, FrameType *frame)
 
FrameTypeGetVideoImagerToolFrame (VideoImagerToolType *videoImagerTool)
 
void SetVideoImagerToolUpdate (VideoImagerToolType *videoImagerTool, bool flag) const
 Turn on/off update flag of the VideoImager tool. More...
 
void ExitImagingStateProcessing (void)
 Always called when exiting imaging state. More...
 
void ExitImagingWithoutTerminatingImagingThread ()
 Exit imaging without terminating imaging thread. More...
 
void ExitImagingTerminatingImagingThread ()
 Exit imaging after terminating imaging thread. More...
 
- Protected Member Functions inherited from igstk::Object
LoggerTypeGetLogger () const
 
 Object (void)
 Constructor is protected in order to enforce the use of the New() operator. More...
 
virtual ~Object (void)
 
void RegisterObservedObject (const ::igstk::Object *object, unsigned long tag)
 Register observed objects in an internal array so that they can be disconnected upon destruction. More...
 
void RemoveFromObservedObjects ()
 Remove observers that this object may have connected to other objects. More...
 

Additional Inherited Members

- Public Types inherited from igstk::Object
typedef Object Self
 General Typedefs. More...
 
typedef ::itk::Object Superclass
 
typedef ::itk::SmartPointer< SelfPointer
 
typedef ::itk::SmartPointer
< const Self
ConstPointer
 
typedef igstk::Logger LoggerType
 
- Public Member Functions inherited from igstk::VideoImager
void RequestOpen (void)
 The "RequestOpen" method attempts to open communication with the imaging device. More...
 
void RequestClose (void)
 The "RequestClose" method closes communication with the device. More...
 
void RequestReset (void)
 The "RequestReset" method should be used to bring the VideoImager to some defined default state. More...
 
void RequestStartImaging (void)
 The "RequestStartImaging" method readies the VideoImager for imaging the tools connected to the VideoImager. More...
 
void RequestStopImaging (void)
 The "RequestStopImaging" stops VideoImager from imaging the tools. More...
 
void RequestSetFrequency (double frequencyInHz)
 The "RequestSetFrequency" method defines the frequency at which a frame will be queried from the VideoImager device. More...
 
- Public Member Functions inherited from igstk::Object
virtual const char * GetNameOfClass () const
 
void SetLogger (LoggerType *logger)
 Connect the Logger for this class. More...
 
void RemoveObserver (unsigned long tag) const
 
- Static Public Member Functions inherited from igstk::Object
static Pointer New (void)
 

Detailed Description

This derivation of the VideoImager class provides communication to a Webcam in Windows.

Definition at line 49 of file igstkWebcamWinVideoImager.h.

Member Typedef Documentation

Typedef for internal boolean return type.

Definition at line 67 of file igstkWebcamWinVideoImager.h.

Constructor & Destructor Documentation

igstk::WebcamWinVideoImager::WebcamWinVideoImager ( void  )
protected
virtual igstk::WebcamWinVideoImager::~WebcamWinVideoImager ( void  )
protectedvirtual

Member Function Documentation

virtual ResultType igstk::WebcamWinVideoImager::InternalOpen ( void  )
protectedvirtual

Open communication with the imaging device.

Implements igstk::VideoImager.

virtual ResultType igstk::WebcamWinVideoImager::InternalClose ( void  )
protectedvirtual

Close communication with the imaging device.

Implements igstk::VideoImager.

virtual ResultType igstk::WebcamWinVideoImager::InternalStartImaging ( void  )
protectedvirtual

Put the imaging device into imaging mode.

Implements igstk::VideoImager.

virtual ResultType igstk::WebcamWinVideoImager::InternalStopImaging ( void  )
protectedvirtual

Take the imaging device out of imaging mode.

Implements igstk::VideoImager.

virtual ResultType igstk::WebcamWinVideoImager::InternalUpdateStatus ( void  )
protectedvirtual

Update the status and the transforms for all VideoImagerTools.

Implements igstk::VideoImager.

virtual ResultType igstk::WebcamWinVideoImager::InternalThreadedUpdateStatus ( void  )
protectedvirtual

Update the status and the frames.

This function is called by a separate thread.

Implements igstk::VideoImager.

virtual ResultType igstk::WebcamWinVideoImager::InternalReset ( void  )
protectedvirtual

Reset the imaging device to put it back to its original state.

Implements igstk::VideoImager.

virtual ResultType igstk::WebcamWinVideoImager::VerifyVideoImagerToolInformation ( const VideoImagerToolType )
protectedvirtual

Verify imager tool information.

Implements igstk::VideoImager.

virtual ResultType igstk::WebcamWinVideoImager::ValidateSpecifiedFrequency ( double  frequencyInHz)
protectedvirtual

The "ValidateSpecifiedFrequency" method checks if the specified frequency is valid for the imaging device that is being used.

Reimplemented from igstk::VideoImager.

virtual void igstk::WebcamWinVideoImager::PrintSelf ( std::ostream &  os,
itk::Indent  indent 
) const
protectedvirtual

Print object information.

Reimplemented from igstk::VideoImager.

virtual ResultType igstk::WebcamWinVideoImager::RemoveVideoImagerToolFromInternalDataContainers ( const VideoImagerToolType imagerTool)
protectedvirtual

Remove imager tool entry from internal containers.

Implements igstk::VideoImager.

virtual ResultType igstk::WebcamWinVideoImager::AddVideoImagerToolToInternalDataContainers ( const VideoImagerToolType imagerTool)
protectedvirtual

Add imager tool entry to internal containers.

Implements igstk::VideoImager.

Member Data Documentation

igstk::WebcamWinVideoImager::igstkStandardClassTraitsMacro(WebcamWinVideoImager, VideoImager) public

Macro with standard traits declarations.

Get the number of tools that have been detected.

Definition at line 53 of file igstkWebcamWinVideoImager.h.

itk::MutexLock::Pointer igstk::WebcamWinVideoImager::m_FrameBufferLock
static

Members and functions for communication with the webcam.

A mutex for multithreaded access to frameBuffer

Definition at line 138 of file igstkWebcamWinVideoImager.h.


The documentation for this class was generated from the following file: