diff --git a/backend/src/RenderVideo.py b/backend/src/RenderVideo.py index ebc6e43c..53e16360 100644 --- a/backend/src/RenderVideo.py +++ b/backend/src/RenderVideo.py @@ -207,7 +207,7 @@ def getTransitionFrame(self): def render(self): self.currentTransitionFrameNumber = self.getTransitionFrame() - counter = -1 + counter = 0 while True: if not self.isPaused: frame = self.readQueue.get() diff --git a/backend/src/SceneDetect.py b/backend/src/SceneDetect.py index 02b3a78a..ced041ea 100644 --- a/backend/src/SceneDetect.py +++ b/backend/src/SceneDetect.py @@ -84,7 +84,7 @@ def getPySceneDetectTransitions(self) -> Queue: # sceneChangeList += detectedFrameList match len(detectedFrameList): case 1: - sceneChangeQueue.put(detectedFrameList[0] - 1) + sceneChangeQueue.put(detectedFrameList[0]) return sceneChangeQueue def getMeanTransitions(self): @@ -96,7 +96,7 @@ def getMeanTransitions(self): self.readQueue.get(), width=self.width, height=self.height ) if detector.sceneDetect(frame): - sceneChangeQueue.put(frame_num - 1) + sceneChangeQueue.put(frame_num ) return sceneChangeQueue def getTransitions(self) -> Queue: