diff options
| author | Carl Hetherington <cth@carlh.net> | 2013-10-15 15:26:04 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2013-10-15 15:26:04 +0100 |
| commit | 45f9912aa850546e319e32a4052517d67f4e3d8f (patch) | |
| tree | f92b43f73e82cd09bf6a3bea29147aafa9c59d79 /src/lib/ratio.cc | |
| parent | 708dacb8247c73c02b6192464325738203ca001a (diff) | |
Allow no-stretch scaling of video content.
Diffstat (limited to 'src/lib/ratio.cc')
| -rw-r--r-- | src/lib/ratio.cc | 14 |
1 files changed, 1 insertions, 13 deletions
diff --git a/src/lib/ratio.cc b/src/lib/ratio.cc index 5988b3418..41abbb760 100644 --- a/src/lib/ratio.cc +++ b/src/lib/ratio.cc @@ -19,6 +19,7 @@ #include <libdcp/types.h> #include "ratio.h" +#include "util.h" #include "i18n.h" @@ -28,19 +29,6 @@ using std::vector; vector<Ratio const *> Ratio::_ratios; -libdcp::Size -Ratio::size (libdcp::Size full_frame) const -{ - if (_ratio < static_cast<float>(full_frame.width) / full_frame.height) { - return libdcp::Size (full_frame.height * _ratio, full_frame.height); - } else { - return libdcp::Size (full_frame.width, full_frame.width / _ratio); - } - - return libdcp::Size (); -} - - void Ratio::setup_ratios () { |
