bitwarden

This commit is contained in:
jaydee
2024-09-26 17:21:12 +02:00

View File

@@ -181,9 +181,13 @@ if _ACTION == "join":
myCmd = [
"/opt/ffmpeg/ffmpeg", "-f", "concat", "-i", "video.txt ","-vcodec", "copy", "-acodec", "copy", "-y", export_name
]
#print(myCmd)
if _TEST:
print(" ".join(myCmd))
print(f"Joining {len(parts)} files to {export_name} in {_DAY_DIR}...")
try:
os.remove(export_name)
except:
pass
proc = subprocess.Popen(myCmd,stdout=subprocess.DEVNULL,stderr=subprocess.STDOUT)
# with tqdm(total=100, position=1, desc="Convert") as pbar:
# for progress in ff.run_command_with_progress():
@@ -216,7 +220,7 @@ if _ACTION == "join":
# get the output
status = 0
if status == 0:
if status == 0 and not _TEST:
print("Moving...")
for p in parts:
try:
@@ -276,7 +280,7 @@ if _ACTION == "encode":
myCmd = [
"/opt/ffmpeg/ffmpeg", "-i", p, "-c:v", "hevc_amf", "-rc", "cqp", "-qp_i", _QUALITY[0], "-qp_p", _QUALITY[1], "-quality", "quality", "-crf", _QUALITY[2], "-y", export_name , "-f", "null", "/dev/null",
]
print(myCmd)
#print(myCmd)
print(f"Encoding {p} to {export_name} in {_DAY_DIR}...")
ff = FfmpegProgress(myCmd)
with tqdm(total=100, position=1, desc="Encode") as pbar: