Logo Search packages:      
Sourcecode: gnome-mousetrap version File versions  Download package

def mouseTrap::cam::Camera::_checkImg (   self  )  [private]

Perform the checks to the image and the capture  actions.

Arguments:
- self: The main object pointer.

Definition at line 134 of file cam.py.

00134                          :
        """
        Perform the checks to the image and the capture  actions.
        
        Arguments:
        - self: The main object pointer.
        """
        
        self.cmQueryCapture( flip = self.settings.getboolean( "cam", "flipImage" ) )
        
        # create a self.gray version of the self.img
        cv.cvCvtColor (self.img, self.grey, cv.CV_BGR2GRAY)

        #if not self.foreheadOrig and not self.forehead:
        if not self.imgLKPoints["last"]:
            self._setForehead( self.cmGetHaarPoints( self.haarCds['Face'] ) )

        if len(self.imgLKPoints["last"]) > 0:
            self.cmShowLKPoints()
            self._procCapture()
        
        self.cmSwapLKPoints()

        #if self.forehead:
         #   cv.cvRectangle( self.img, cv.cvPoint( self.forehead.x - 100, self.forehead.y ), 
          # cv.cvPoint( self.forehead.x, self.forehead.y + 70 ), cv.CV_RGB(255,0,0), 3, 8, 0 );  
           # self.checkBlink()
            
        # we can now display the self.img
        highgui.cvConvertImage( self.img, self.img, highgui.CV_CVTIMG_SWAP_RB )
        mouseTrap.updateView( self.img )
        
        # handle events
        c = self.cmWaitKey(10)
        return self.run


    def _setForehead( self, face ):


Generated by  Doxygen 1.6.0   Back to index