mirror of
https://cdm-project.com/Download-Tools/udemy-downloader.git
synced 2025-05-06 01:14:27 +02:00
Fixed an unexpected error where the program would try to execute the ffmpeg.py file instead of the .exe during mux process
This commit is contained in:
parent
f8521fd84c
commit
6c2690b856
@ -14,7 +14,11 @@ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVE
|
|||||||
ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH
|
ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH
|
||||||
THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||||
"""
|
"""
|
||||||
import re, time, logging, subprocess, sys
|
import re
|
||||||
|
import time
|
||||||
|
import logging
|
||||||
|
import subprocess
|
||||||
|
import sys
|
||||||
from colorama import Fore, Style
|
from colorama import Fore, Style
|
||||||
|
|
||||||
|
|
||||||
|
7
main.py
7
main.py
@ -787,12 +787,12 @@ def mux_process(video_title, lecture_working_dir, output_path):
|
|||||||
@author Jayapraveen
|
@author Jayapraveen
|
||||||
"""
|
"""
|
||||||
if os.name == "nt":
|
if os.name == "nt":
|
||||||
command = "ffmpeg -y -i \"{}\" -i \"{}\" -acodec copy -vcodec copy -fflags +bitexact -map_metadata -1 -metadata title=\"{}\" \"{}\"".format(
|
command = "ffmpeg.exe -y -i \"{}\" -i \"{}\" -acodec copy -vcodec copy -fflags +bitexact -map_metadata -1 -metadata title=\"{}\" \"{}\"".format(
|
||||||
os.path.join(lecture_working_dir, "decrypted_audio.mp4"),
|
os.path.join(lecture_working_dir, "decrypted_audio.mp4"),
|
||||||
os.path.join(lecture_working_dir, "decrypted_video.mp4"),
|
os.path.join(lecture_working_dir, "decrypted_video.mp4"),
|
||||||
video_title, output_path)
|
video_title, output_path)
|
||||||
else:
|
else:
|
||||||
command = "nice -n 7 ffmpeg -y -i \"{}\" -i \"{}\" -acodec copy -vcodec copy -fflags +bitexact -map_metadata -1 -metadata title=\"{}\" \"{}\"".format(
|
command = "nice -n 7 ffmpeg.exe -y -i \"{}\" -i \"{}\" -acodec copy -vcodec copy -fflags +bitexact -map_metadata -1 -metadata title=\"{}\" \"{}\"".format(
|
||||||
os.path.join(lecture_working_dir, "decrypted_audio.mp4"),
|
os.path.join(lecture_working_dir, "decrypted_audio.mp4"),
|
||||||
os.path.join(lecture_working_dir, "decrypted_video.mp4"),
|
os.path.join(lecture_working_dir, "decrypted_video.mp4"),
|
||||||
video_title, output_path)
|
video_title, output_path)
|
||||||
@ -807,8 +807,7 @@ def decrypt(kid, filename, lecture_working_dir):
|
|||||||
try:
|
try:
|
||||||
key = keyfile[kid.lower()]
|
key = keyfile[kid.lower()]
|
||||||
if (os.name == "nt"):
|
if (os.name == "nt"):
|
||||||
code = os.system(
|
os.system(f"mp4decrypt --key 1:%s \"%s\" \"%s\"" %
|
||||||
f"mp4decrypt --key 1:%s \"%s\" \"%s\"" %
|
|
||||||
(key,
|
(key,
|
||||||
os.path.join(lecture_working_dir,
|
os.path.join(lecture_working_dir,
|
||||||
"encrypted_{}.mp4".format(filename)),
|
"encrypted_{}.mp4".format(filename)),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user