mirror of
https://github.com/k4yt3x/video2x.git
synced 2025-01-30 23:58:11 +00:00
Merge branch 'master' of https://github.com/k4yt3x/video2x into master
This commit is contained in:
commit
458ce82644
@ -1,7 +1,7 @@
|
|||||||
# Name: Video2X Configuration File
|
# Name: Video2X Configuration File
|
||||||
# Creator: K4YT3X
|
# Creator: K4YT3X
|
||||||
# Date Created: October 23, 2018
|
# Date Created: October 23, 2018
|
||||||
# Last Modified: September 21, 2020
|
# Last Modified: September 28, 2020
|
||||||
# Values here are the default values. Change the value here to
|
# Values here are the default values. Change the value here to
|
||||||
# save the default value permanently.
|
# save the default value permanently.
|
||||||
# Items commented out are parameters irrelevant to this context
|
# Items commented out are parameters irrelevant to this context
|
||||||
@ -120,7 +120,7 @@ anime4kcpp:
|
|||||||
webVideo: null # process the video from URL
|
webVideo: null # process the video from URL
|
||||||
alpha: false # preserve the Alpha channel for transparent image
|
alpha: false # preserve the Alpha channel for transparent image
|
||||||
ffmpeg:
|
ffmpeg:
|
||||||
ffmpeg_path: '%LOCALAPPDATA%\video2x\ffmpeg-latest-win64-static\bin'
|
ffmpeg_path: '%LOCALAPPDATA%\video2x\ffmpeg\bin'
|
||||||
intermediate_file_name: 'intermediate.mkv'
|
intermediate_file_name: 'intermediate.mkv'
|
||||||
# Step 1: Frame Extraction
|
# Step 1: Frame Extraction
|
||||||
# extract all frames from original input into temporary directory
|
# extract all frames from original input into temporary directory
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
Name: Video2X Setup Script
|
Name: Video2X Setup Script
|
||||||
Creator: K4YT3X
|
Creator: K4YT3X
|
||||||
Date Created: November 28, 2018
|
Date Created: November 28, 2018
|
||||||
Last Modified: May 30, 2020
|
Last Modified: September 28, 2020
|
||||||
|
|
||||||
Editor: BrianPetkovsek
|
Editor: BrianPetkovsek
|
||||||
Editor: SAT3LL
|
Editor: SAT3LL
|
||||||
@ -44,7 +44,7 @@ import zipfile
|
|||||||
# Therefore, they will be installed during the Python dependency
|
# Therefore, they will be installed during the Python dependency
|
||||||
# installation step and imported later in the script.
|
# installation step and imported later in the script.
|
||||||
|
|
||||||
SETUP_VERSION = '2.2.1'
|
SETUP_VERSION = '2.3.0'
|
||||||
|
|
||||||
# global static variables
|
# global static variables
|
||||||
LOCALAPPDATA = pathlib.Path(os.getenv('localappdata'))
|
LOCALAPPDATA = pathlib.Path(os.getenv('localappdata'))
|
||||||
@ -126,14 +126,22 @@ class Video2xSetup:
|
|||||||
"""
|
"""
|
||||||
print('\nInstalling FFmpeg')
|
print('\nInstalling FFmpeg')
|
||||||
|
|
||||||
latest_release = 'https://ffmpeg.zeranoe.com/builds/win64/static/ffmpeg-latest-win64-static.zip'
|
latest_release = 'https://www.gyan.dev/ffmpeg/builds/ffmpeg-release-full.zip'
|
||||||
|
|
||||||
ffmpeg_zip = download(latest_release, tempfile.gettempdir())
|
ffmpeg_zip = download(latest_release, tempfile.gettempdir())
|
||||||
self.trash.append(ffmpeg_zip)
|
self.trash.append(ffmpeg_zip)
|
||||||
|
|
||||||
|
ffmpeg_directory = LOCALAPPDATA / 'video2x' / 'ffmpeg'
|
||||||
with zipfile.ZipFile(ffmpeg_zip) as zipf:
|
with zipfile.ZipFile(ffmpeg_zip) as zipf:
|
||||||
zipf.extractall(LOCALAPPDATA / 'video2x')
|
zipf.extractall(LOCALAPPDATA / 'video2x')
|
||||||
|
|
||||||
|
# if directory already exists, remove it
|
||||||
|
if ffmpeg_directory.exists():
|
||||||
|
shutil.rmtree(ffmpeg_directory)
|
||||||
|
|
||||||
|
# rename the newly extracted directory
|
||||||
|
(LOCALAPPDATA / 'video2x' / zipf.namelist()[0]).rename(ffmpeg_directory)
|
||||||
|
|
||||||
def _install_gifski(self):
|
def _install_gifski(self):
|
||||||
print('\nInstalling Gifski')
|
print('\nInstalling Gifski')
|
||||||
import requests
|
import requests
|
||||||
|
Loading…
Reference in New Issue
Block a user