At line 118 in function __seek_for_frame, should follow a "break", one frame is enough for thumbnail creating. Otherwise repeat 5 times.
--------------------------------------------
for location in frame_locations: abs_location = int(location * duration)
event = self._pipeline.seek(1.0, gst.FORMAT_TIME, gst.SEEK_FLAG_FLUSH | gst.SEEK_FLAG_KEY_UNIT, gst.SEEK_TYPE_SET, abs_location, gst.SEEK_TYPE_NONE, 0)
if not event:
raise VideoFrameError("Not Seekable")
if not self.set_state_blocking(self._pipeline, gst.STATE_PAUSED): raise VideoFrameError("Not Pausable")
frame = self._sink.get_current_frame()
img = Image.frombuffer("RGB", sink_size, frame, "raw", "RGB", 0, 1)
--------------------------------------------
attach root cause,
At line 118 in function __seek_for_frame, should follow a "break", one frame is enough for thumbnail creating. Otherwise repeat 5 times. ------- ------- ------- ------- ------- --
abs_ location = int(location * duration) seek(1. 0, gst.FORMAT_TIME,
gst. SEEK_FLAG_ FLUSH | gst.SEEK_ FLAG_KEY_ UNIT,
gst. SEEK_TYPE_ SET, abs_location,
gst. SEEK_TYPE_ NONE, 0) ("Not Seekable")
-------
for location in frame_locations:
event = self._pipeline.
if not event:
raise VideoFrameError
if not self.set_ state_blocking( self._pipeline, gst.STATE_PAUSED):
raise VideoFrameError ("Not Pausable") get_current_ frame() r("RGB" , sink_size, frame, "raw", "RGB", 0, 1) ------- ------- ------- ------- ------- --
frame = self._sink.
img = Image.frombuffe
-------