Skip to content

Commit

Permalink
fixing pydantic error with resolutions
Browse files Browse the repository at this point in the history
  • Loading branch information
cdgriffith committed Aug 9, 2024
1 parent bd14e52 commit d3b47e7
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 9 deletions.
2 changes: 1 addition & 1 deletion CHANGES
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* Fixing #522 add file fails - fixed as of 5.7.0 (thanks to pcl5x2008)
* Fixing #531 list limitation in readme that FFmpeg must support the software encoders listed (thanks to brunoais)
* Fixing #567 Profiles for WebP did not work (nor GIF dither) (thanks to jpert)
* Fixing #582 BT.2020-10 Color transfer not maintained #582 (thanks to Ryushin)
* Fixing #582 BT.2020-10 Color transfer not maintained (thanks to Ryushin)
* Fixing #585 error when trying to return a video from queue that has the video track after audio or subtitiles (thanks to Hankuu)
* Fixing #586 audio channels being set incorrectly (thanks to Hankuu)
* Fixing #588 audio and subtitle dispositions were not set from source (thanks to GeZorTenPlotZ)
Expand Down
7 changes: 1 addition & 6 deletions fastflix/encoders/webp/settings_panel.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,12 +81,7 @@ def update_video_encoder_settings(self):
pix_fmt="yuv420p", # hack for thumbnails to show properly
extra_both_passes=self.widgets.extra_both_passes.isChecked(),
)
_, qscale = self.get_mode_settings()
try:
settings.qscale = float(qscale)
except ValueError:
logger.warning("Invalid Qscale, using default 75")
settings.qscale = 75
_, settings.qscale = self.get_mode_settings()
self.app.fastflix.current_video.video_settings.video_encoder_settings = settings

def new_source(self):
Expand Down
5 changes: 4 additions & 1 deletion fastflix/widgets/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,12 +71,15 @@
t("Custom (w:h)"): {"method": "custom"},
"4320 LE": {"method": "long edge", "pixels": 4320},
"2160 LE": {"method": "long edge", "pixels": 2160},
"1920 LE": {"method": "long edge", "pixels": 1920},
"1440 LE": {"method": "long edge", "pixels": 1440},
"1280 LE": {"method": "long edge", "pixels": 1280},
"1080 LE": {"method": "long edge", "pixels": 1080},
"720 LE": {"method": "long edge", "pixels": 720},
"480 LE": {"method": "long edge", "pixels": 480},
"4320 H": {"method": "height", "pixels": 4320},
"2160 H": {"method": "height", "pixels": 2160},
"1920 H": {"method": "height", "pixels": 1920},
"1440 H": {"method": "height", "pixels": 1440},
"1080 H": {"method": "height", "pixels": 1080},
"720 H": {"method": "height", "pixels": 720},
Expand Down Expand Up @@ -1697,7 +1700,7 @@ def resolution_method(self):
def resolution_custom(self):
res = resolutions[self.widgets.resolution_drop_down.currentText()]
if "pixels" in res:
return res["pixels"]
return str(res["pixels"])
if self.widgets.resolution_custom.text().strip():
return self.widgets.resolution_custom.text()

Expand Down
2 changes: 1 addition & 1 deletion fastflix/widgets/windows/disposition.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ def __init__(self, app: FastFlixApp, parent, track_name, track_index, audio=True
self.track_index = track_index
self.audio = audio

self.setMinimumWidth(400)
self.setMinimumWidth(200)

self.forced = QtWidgets.QCheckBox(t("Forced"))

Expand Down

0 comments on commit d3b47e7

Please sign in to comment.