Advertisement
cooperlees

Untitled

Apr 7th, 2021
1,384
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Diff 1.35 KB | None | 0 0
  1. crl-m1:clc_ansible cooper$ git diff
  2. diff --git a/camera_archiver/files/ca.py b/camera_archiver/files/ca.py
  3. index 3fe3843..20f2afc 100644
  4. --- a/camera_archiver/files/ca.py
  5. +++ b/camera_archiver/files/ca.py
  6. @@ -69,23 +69,23 @@ def timelapse_generate(archive_path: Path, date: str, cam_name: str) -> None:
  7.      # Make sure we don't have any zero-length snapshots
  8.      # It will truncate the timelapse
  9.      snap_glob = list(archive_path.glob(f"{cam_name}_*.jpg"))
  10. -    for f in [x for x in snap_glob  if x.stat().st_size == 0]:
  11. +    for f in [x for x in snap_glob if x.stat().st_size == 0]:
  12.          f.unlink()
  13.  
  14.      output_options = {
  15. -        'c:v': 'libx265',
  16. -        'b:v': '10M',
  17. -        'f': 'mp4' ,
  18. -        'tag:v': 'hvc1',
  19. -        'movflags': '+faststart',
  20. -        'pix_fmt': 'p010le',
  21. -        'profile:v': 'main10',
  22. +        "c:v": "libx265",
  23. +        "b:v": "10M",
  24. +        "f": "mp4",
  25. +        "tag:v": "hvc1",
  26. +        "movflags": "+faststart",
  27. +        "pix_fmt": "p010le",
  28. +        "profile:v": "main10",
  29.      }
  30.      ffmpeg.input(
  31.          f"{archive_path.as_posix()}/{cam_name}_*.jpeg",
  32.          pattern_type="glob",
  33.          framerate=30,
  34. -    ).output(timelapse_path.as_posix(), **output_options}).overwrite_output().run()
  35. +    ).output(timelapse_path.as_posix(), **output_options).overwrite_output().run()
  36.  
  37.  
  38.  def main() -> int:
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement