示例#1
0
文件: video.py 项目: Resonanz/pims
 def __init__(self, filename, gray=True, invert=True):
     BaseFrames.__init__(self, filename, gray, invert)
     self.shape = (int(self.capture.get(cv2.cv.CV_CAP_PROP_FRAME_WIDTH)),
                   int(self.capture.get(cv2.cv.CV_CAP_PROP_FRAME_HEIGHT)))
     self.count = int(self.capture.get(cv2.cv.CV_CAP_PROP_FRAME_COUNT))
示例#2
0
 def __init__(self, filename, gray=True, invert=True):
     BaseFrames.__init__(self, filename, gray, invert)
     dummy_instance = self._open(filename)
     self.count = dummy_instance._count
     self.shape = dummy_instance._shape
示例#3
0
 def __init__(self, directory, gray=True, invert=True):
     BaseFrames.__init__(self, directory, gray, invert)
     dummy_instance = self._open(directory)
     self.count = len(dummy_instance.files)
     self.shape = imread(dummy_instance.files[0]).shape