diff options
| author | Carl Hetherington <cth@carlh.net> | 2013-01-26 22:51:54 +0000 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2013-01-26 22:51:54 +0000 |
| commit | b1873c51b2e8265a01a8f0eced7fc3465f1677dc (patch) | |
| tree | d0eb1d779f6f9e145e57693162af06a2390e84fb /src/lib/format.cc | |
| parent | 494b6ee180e531358bab39e72f6123e90f9314e5 (diff) | |
| parent | d641aee73077e93ca17b30acd5b9ed82f1e14cb9 (diff) | |
Merge master into direct-mxf.
Diffstat (limited to 'src/lib/format.cc')
| -rw-r--r-- | src/lib/format.cc | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/lib/format.cc b/src/lib/format.cc index 4583dd0e5..016c21fde 100644 --- a/src/lib/format.cc +++ b/src/lib/format.cc @@ -148,6 +148,9 @@ FixedFormat::FixedFormat (int r, libdcp::Size dcp, string id, string n, string d } +/** @return Number of pixels (int the DCP image) to pad either side of the film + * (so there are dcp_padding() pixels on the left and dcp_padding() on the right) + */ int Format::dcp_padding (shared_ptr<const Film> f) const { @@ -161,6 +164,12 @@ Format::dcp_padding (shared_ptr<const Film> f) const return p; } +float +Format::container_ratio_as_float () const +{ + return static_cast<float> (_dcp_size.width) / _dcp_size.height; +} + VariableFormat::VariableFormat (libdcp::Size dcp, string id, string n, string d) : Format (dcp, id, n, d) { |
