From 689fa55d1529ad88449ca464e9107c4dcc54d1cb Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Mon, 3 May 2021 11:17:34 +0200 Subject: C++11 tidying. --- src/lib/atmos_mxf_decoder.cc | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'src/lib/atmos_mxf_decoder.cc') diff --git a/src/lib/atmos_mxf_decoder.cc b/src/lib/atmos_mxf_decoder.cc index 6c7cda61a..9fcd9d2a6 100644 --- a/src/lib/atmos_mxf_decoder.cc +++ b/src/lib/atmos_mxf_decoder.cc @@ -1,5 +1,5 @@ /* - Copyright (C) 2020 Carl Hetherington + Copyright (C) 2020-2021 Carl Hetherington This file is part of DCP-o-matic. @@ -18,6 +18,7 @@ */ + #include "atmos_content.h" #include "atmos_decoder.h" #include "atmos_mxf_content.h" @@ -26,15 +27,18 @@ #include #include + +using std::make_shared; using std::shared_ptr; + AtmosMXFDecoder::AtmosMXFDecoder (std::shared_ptr film, std::shared_ptr content) : Decoder (film) , _content (content) { - atmos.reset (new AtmosDecoder(this, content)); + atmos = make_shared(this, content); - shared_ptr asset (new dcp::AtmosAsset(_content->path(0))); + auto asset = make_shared(_content->path(0)); _reader = asset->start_read (); _metadata = AtmosMetadata (asset); } @@ -43,8 +47,8 @@ AtmosMXFDecoder::AtmosMXFDecoder (std::shared_ptr film, std::shared_ bool AtmosMXFDecoder::pass () { - double const vfr = _content->active_video_frame_rate (film()); - int64_t const frame = _next.frames_round (vfr); + auto const vfr = _content->active_video_frame_rate (film()); + auto const frame = _next.frames_round (vfr); if (frame >= _content->atmos->length()) { return true; -- cgit v1.2.3