Skip to content

Commit

Permalink
Make paths platform independent
Browse files Browse the repository at this point in the history
  • Loading branch information
kirek007 committed Jan 3, 2023
1 parent da9db2a commit 4b19612
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions processor.py
Original file line number Diff line number Diff line change
Expand Up @@ -344,9 +344,11 @@ def render(self):
else:
ff_size = {"w": video_size[1], "h": video_size[0]}


out_path = os.path.join(self.output, "ws_%09d.png")
osd_frame = (
ffmpeg
.input("%s\%s" % (self.output, "ws_%09d.png"), framerate=60)
.input(out_path, framerate=60)
.filter("scale", **ff_size, force_original_aspect_ratio=0)
)

Expand Down Expand Up @@ -411,7 +413,8 @@ def main(self):
Utils.merge_images(frame, osd_frame, self.config.offset_left, self.config.offset_top, self.config.osd_zoom)
osd_time = raw_osd_frame.startTime

cv2.imwrite("%s/ws_%09d.png" % (self.output, current_frame), frame)
out_path = os.path.join(self.output, "ws_%09d.png" % (current_frame))
cv2.imwrite(out_path, frame)


current_frame+=1
Expand Down

0 comments on commit 4b19612

Please sign in to comment.