示例#1
0
 def setExposure(self, exposureVale):
     if self.running:
         self.stopAcquisition()
         self.readyCapture = False
     exposure = PyCapture2.Property()
     exposure.type = PyCapture2.PROPERTY_TYPE.AUTO_EXPOSURE
     exposure.onOff = True
     exposure.autoManualMode = False
     exposure.absControl = True
     exposure.absValue = exposureVale
     self.camera.setProperty(exposure)
     self.readyCapture = True
示例#2
0
    def setGain(self, gainValue):
        """

        :param gainValue:
        :return:
        """
        if self.running:
            self.stopAcquisition()
            self.readyCapture = False
        gain = PyCapture2.Property()
        gain.type = PyCapture2.PROPERTY_TYPE.GAIN
        gain.onOff = True
        gain.autoManualMode = False
        gain.absControl = True
        gain.absValue = gainValue
        self.camera.setProperty(gain)
        self.readyCapture = True
示例#3
0
 def setShutter(self, shutterValue):
     """
     Shutter times are scaled by the divider of the basic frame rate.
     For example, dividing the frame rate by two(e.g.15FPS to7.5FPS)
     causes the maximum shutter time to double(e.g.66ms to 133ms).
     :param shutterValue:  int(ms)
     :return:
     """
     if self.running:
         self.stopAcquisition()
         self.readyCapture = False
     shutter = PyCapture2.Property()
     shutter.type = PyCapture2.PROPERTY_TYPE.SHUTTER
     shutter.onOff = True
     shutter.autoManualMode = False
     shutter.absControl = True
     shutter.absValue = shutterValue
     self.camera.setProperty(shutter)
     self.readyCapture = True