diff options
| author | Carl Hetherington <cth@carlh.net> | 2023-10-10 01:05:27 +0200 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2023-10-10 01:05:30 +0200 |
| commit | ba438ecd16207700ffd849820796b6f833beef21 (patch) | |
| tree | 7d37e4ba4322e74204fb4a210657fa8bba6af385 /src/lib | |
| parent | b56481622c385732ae9ba2affd38ae7b820aab45 (diff) | |
Add new "copy markers from this DCP" option (#2628).
Also stop the "copy settings" options from doing this, as Carsten points
out that it could be confusing and potentially very bad if you copy
markers from an OV to an edited VF which then bring house lights up at
the wrong time or whatever.
Diffstat (limited to 'src/lib')
| -rw-r--r-- | src/lib/copy_dcp_details_to_film.cc | 13 | ||||
| -rw-r--r-- | src/lib/copy_dcp_details_to_film.h | 1 |
2 files changed, 10 insertions, 4 deletions
diff --git a/src/lib/copy_dcp_details_to_film.cc b/src/lib/copy_dcp_details_to_film.cc index 206475ed6..669fc8ac9 100644 --- a/src/lib/copy_dcp_details_to_film.cc +++ b/src/lib/copy_dcp_details_to_film.cc @@ -61,12 +61,17 @@ copy_dcp_settings_to_film(shared_ptr<const DCPContent> dcp, shared_ptr<Film> fil film->set_audio_channels (dcp->audio->stream()->channels()); } + film->set_ratings (dcp->ratings()); + film->set_content_versions (dcp->content_versions()); +} + + +void +copy_dcp_markers_to_film(shared_ptr<const DCPContent> dcp, shared_ptr<Film> film) +{ film->clear_markers (); for (auto const& i: dcp->markers()) { - film->set_marker (i.first, dcpomatic::DCPTime(i.second.get())); + film->set_marker(i.first, dcpomatic::DCPTime(i.second.get())); } - - film->set_ratings (dcp->ratings()); - film->set_content_versions (dcp->content_versions()); } diff --git a/src/lib/copy_dcp_details_to_film.h b/src/lib/copy_dcp_details_to_film.h index 99f9cdeb7..0948cbec1 100644 --- a/src/lib/copy_dcp_details_to_film.h +++ b/src/lib/copy_dcp_details_to_film.h @@ -27,3 +27,4 @@ class Film; extern void copy_dcp_settings_to_film(std::shared_ptr<const DCPContent> dcp, std::shared_ptr<Film> film); +extern void copy_dcp_markers_to_film(std::shared_ptr<const DCPContent> dcp, std::shared_ptr<Film> film); |
