diff options
| author | Carl Hetherington <cth@carlh.net> | 2020-05-10 00:23:48 +0200 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2020-05-10 00:23:48 +0200 |
| commit | 2632343cc712188e0db2afa1e551e4a5086e70fa (patch) | |
| tree | 489fc513bb6f4f5af591ffb792e89fb663fa24b4 /src/lib | |
| parent | 3e96f929fdf740f414b114c5d9765e22fcc46de6 (diff) | |
Remove scale to fit {width,height} options.
Diffstat (limited to 'src/lib')
| -rw-r--r-- | src/lib/video_content.cc | 23 | ||||
| -rw-r--r-- | src/lib/video_content.h | 3 |
2 files changed, 0 insertions, 26 deletions
diff --git a/src/lib/video_content.cc b/src/lib/video_content.cc index 685336367..9e8659b98 100644 --- a/src/lib/video_content.cc +++ b/src/lib/video_content.cc @@ -354,29 +354,6 @@ VideoContent::size_after_crop () const return crop().apply (size_after_3d_split ()); } -void -VideoContent::scale_and_crop_to_fit_width (shared_ptr<const Film> film) -{ - set_scale (VideoContentScale(film->container())); - - int const crop = max (0, int (size().height - double (film->frame_size().height) * size().width / film->frame_size().width)); - set_left_crop (0); - set_right_crop (0); - set_top_crop (crop / 2); - set_bottom_crop (crop / 2); -} - -void -VideoContent::scale_and_crop_to_fit_height (shared_ptr<const Film> film) -{ - set_scale (VideoContentScale(film->container())); - - int const crop = max (0, int (size().width - double (film->frame_size().width) * size().height / film->frame_size().height)); - set_left_crop (crop / 2); - set_right_crop (crop / 2); - set_top_crop (0); - set_bottom_crop (0); -} /** @param f Frame index within the whole (untrimmed) content. * @return Fade factor (between 0 and 1) or unset if there is no fade. diff --git a/src/lib/video_content.h b/src/lib/video_content.h index 37223c457..9a7ad6dda 100644 --- a/src/lib/video_content.h +++ b/src/lib/video_content.h @@ -173,9 +173,6 @@ public: boost::optional<double> fade (boost::shared_ptr<const Film> film, Frame) const; - void scale_and_crop_to_fit_width (boost::shared_ptr<const Film> film); - void scale_and_crop_to_fit_height (boost::shared_ptr<const Film> film); - std::string processing_description (boost::shared_ptr<const Film> film) const; void set_length (Frame); |
