Skip to content

Commit

Permalink
make counter less confusing
Browse files Browse the repository at this point in the history
  • Loading branch information
TNTwise committed Sep 26, 2024
1 parent cd2d9d2 commit 89528a6
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion backend/src/RenderVideo.py
Original file line number Diff line number Diff line change
Expand Up @@ -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()
Expand Down
4 changes: 2 additions & 2 deletions backend/src/SceneDetect.py
Original file line number Diff line number Diff line change
Expand Up @@ -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):
Expand All @@ -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:
Expand Down

0 comments on commit 89528a6

Please sign in to comment.