Extract Film::Property to its own header to (maybe) increase compilation speed.
authorCarl Hetherington <cth@carlh.net>
Tue, 8 Aug 2023 16:11:11 +0000 (18:11 +0200)
committerCarl Hetherington <cth@carlh.net>
Wed, 9 Aug 2023 08:18:46 +0000 (10:18 +0200)
49 files changed:
src/lib/analyse_subtitles_job.cc
src/lib/dcp_subtitle_decoder.cc
src/lib/decoder.h
src/lib/film.cc
src/lib/film.h
src/lib/film_property.h [new file with mode: 0644]
src/lib/image_decoder.h
src/lib/player.cc
src/lib/player.h
src/lib/subtitle_encoder.cc
src/lib/util.cc
src/tools/dcpomatic_player.cc
src/wx/audio_dialog.cc
src/wx/audio_dialog.h
src/wx/audio_panel.cc
src/wx/audio_panel.h
src/wx/closed_captions_dialog.cc
src/wx/content_panel.cc
src/wx/content_panel.h
src/wx/content_sub_panel.h
src/wx/controls.cc
src/wx/controls.h
src/wx/dcp_panel.cc
src/wx/dcp_panel.h
src/wx/film_editor.cc
src/wx/film_editor.h
src/wx/film_viewer.cc
src/wx/film_viewer.h
src/wx/gl_video_view.h
src/wx/markers_panel.cc
src/wx/markers_panel.h
src/wx/metadata_dialog.cc
src/wx/metadata_dialog.h
src/wx/playlist_controls.cc
src/wx/smpte_metadata_dialog.cc
src/wx/smpte_metadata_dialog.h
src/wx/standard_controls.cc
src/wx/text_panel.cc
src/wx/text_panel.h
src/wx/timeline.cc
src/wx/timeline.h
src/wx/timeline_dialog.cc
src/wx/timeline_dialog.h
src/wx/timeline_reels_view.cc
src/wx/timing_panel.cc
src/wx/timing_panel.h
src/wx/video_panel.cc
src/wx/video_panel.h
test/ffmpeg_decoder_error_test.cc

index d8d258ea54962af1d86c198242302690744feecb..b41990db5f738dcfc5aad537a96b359861a4948d 100644 (file)
@@ -21,6 +21,7 @@
 
 #include "analyse_subtitles_job.h"
 #include "bitmap_text.h"
+#include "film.h"
 #include "image.h"
 #include "player.h"
 #include "playlist.h"
index fa92193a5a7f384022740a9dbb5fc7ee8e1c1861..b3e6d75531bcbf4fd86ffd0d812aae9558048f19 100644 (file)
@@ -21,6 +21,7 @@
 
 #include "dcp_subtitle_content.h"
 #include "dcp_subtitle_decoder.h"
+#include "film.h"
 #include "font.h"
 #include "text_content.h"
 #include "util.h"
index 34153eafc949f09ee2fcbe7629ec557df111e4b0..7097db88d1b3cf134d35a0dd2725496de8ae4820 100644 (file)
@@ -29,7 +29,6 @@
 
 
 #include "dcpomatic_time.h"
-#include "film.h"
 #include "weak_film.h"
 #include <boost/utility.hpp>
 
index 2840d0236b79029be4dc8ce0045ac43e0a010ef9..2fa720b029969b254b9b40b21dea7ca3abdadfa5 100644 (file)
@@ -1095,21 +1095,21 @@ Film::set_directory (boost::filesystem::path d)
 void
 Film::set_name (string n)
 {
-       FilmChangeSignaller ch (this, Property::NAME);
+       FilmChangeSignaller ch(this, FilmProperty::NAME);
        _name = n;
 }
 
 void
 Film::set_use_isdcf_name (bool u)
 {
-       FilmChangeSignaller ch (this, Property::USE_ISDCF_NAME);
+       FilmChangeSignaller ch(this, FilmProperty::USE_ISDCF_NAME);
        _use_isdcf_name = u;
 }
 
 void
 Film::set_dcp_content_type (DCPContentType const * t)
 {
-       FilmChangeSignaller ch (this, Property::DCP_CONTENT_TYPE);
+       FilmChangeSignaller ch(this, FilmProperty::DCP_CONTENT_TYPE);
        _dcp_content_type = t;
 }
 
@@ -1121,7 +1121,7 @@ Film::set_dcp_content_type (DCPContentType const * t)
 void
 Film::set_container (Ratio const * c, bool explicit_user)
 {
-       FilmChangeSignaller ch (this, Property::CONTAINER);
+       FilmChangeSignaller ch(this, FilmProperty::CONTAINER);
        _container = c;
 
        if (explicit_user) {
@@ -1137,7 +1137,7 @@ Film::set_container (Ratio const * c, bool explicit_user)
 void
 Film::set_resolution (Resolution r, bool explicit_user)
 {
-       FilmChangeSignaller ch (this, Property::RESOLUTION);
+       FilmChangeSignaller ch(this, FilmProperty::RESOLUTION);
        _resolution = r;
 
        if (explicit_user) {
@@ -1149,7 +1149,7 @@ Film::set_resolution (Resolution r, bool explicit_user)
 void
 Film::set_j2k_bandwidth (int b)
 {
-       FilmChangeSignaller ch (this, Property::J2K_BANDWIDTH);
+       FilmChangeSignaller ch(this, FilmProperty::J2K_BANDWIDTH);
        _j2k_bandwidth = b;
 }
 
@@ -1160,7 +1160,7 @@ Film::set_j2k_bandwidth (int b)
 void
 Film::set_video_frame_rate (int f, bool user_explicit)
 {
-       FilmChangeSignaller ch (this, Property::VIDEO_FRAME_RATE);
+       FilmChangeSignaller ch(this, FilmProperty::VIDEO_FRAME_RATE);
        _video_frame_rate = f;
        if (user_explicit) {
                _user_explicit_video_frame_rate = true;
@@ -1170,14 +1170,14 @@ Film::set_video_frame_rate (int f, bool user_explicit)
 void
 Film::set_audio_channels (int c)
 {
-       FilmChangeSignaller ch (this, Property::AUDIO_CHANNELS);
+       FilmChangeSignaller ch(this, FilmProperty::AUDIO_CHANNELS);
        _audio_channels = c;
 }
 
 void
 Film::set_three_d (bool t)
 {
-       FilmChangeSignaller ch (this, Property::THREE_D);
+       FilmChangeSignaller ch(this, FilmProperty::THREE_D);
        _three_d = t;
 
        if (_three_d && _two_d_version_of_three_d) {
@@ -1188,7 +1188,7 @@ Film::set_three_d (bool t)
 void
 Film::set_interop (bool i)
 {
-       FilmChangeSignaller ch (this, Property::INTEROP);
+       FilmChangeSignaller ch(this, FilmProperty::INTEROP);
        _interop = i;
 }
 
@@ -1196,7 +1196,7 @@ Film::set_interop (bool i)
 void
 Film::set_limit_to_smpte_bv20(bool limit)
 {
-       FilmChangeSignaller ch(this, Property::LIMIT_TO_SMPTE_BV20);
+       FilmChangeSignaller ch(this, FilmProperty::LIMIT_TO_SMPTE_BV20);
        _limit_to_smpte_bv20 = limit;
 }
 
@@ -1204,15 +1204,15 @@ Film::set_limit_to_smpte_bv20(bool limit)
 void
 Film::set_audio_processor (AudioProcessor const * processor)
 {
-       FilmChangeSignaller ch1 (this, Property::AUDIO_PROCESSOR);
-       FilmChangeSignaller ch2 (this, Property::AUDIO_CHANNELS);
+       FilmChangeSignaller ch1(this, FilmProperty::AUDIO_PROCESSOR);
+       FilmChangeSignaller ch2(this, FilmProperty::AUDIO_CHANNELS);
        _audio_processor = processor;
 }
 
 void
 Film::set_reel_type (ReelType t)
 {
-       FilmChangeSignaller ch (this, Property::REEL_TYPE);
+       FilmChangeSignaller ch(this, FilmProperty::REEL_TYPE);
        _reel_type = t;
 }
 
@@ -1220,30 +1220,30 @@ Film::set_reel_type (ReelType t)
 void
 Film::set_reel_length (int64_t r)
 {
-       FilmChangeSignaller ch (this, Property::REEL_LENGTH);
+       FilmChangeSignaller ch(this, FilmProperty::REEL_LENGTH);
        _reel_length = r;
 }
 
 void
 Film::set_reencode_j2k (bool r)
 {
-       FilmChangeSignaller ch (this, Property::REENCODE_J2K);
+       FilmChangeSignaller ch(this, FilmProperty::REENCODE_J2K);
        _reencode_j2k = r;
 }
 
 void
 Film::signal_change (ChangeType type, int p)
 {
-       signal_change (type, static_cast<Property>(p));
+       signal_change(type, static_cast<FilmProperty>(p));
 }
 
 void
-Film::signal_change (ChangeType type, Property p)
+Film::signal_change(ChangeType type, FilmProperty p)
 {
        if (type == ChangeType::DONE) {
                set_dirty (true);
 
-               if (p == Property::CONTENT) {
+               if (p == FilmProperty::CONTENT) {
                        if (!_user_explicit_video_frame_rate) {
                                set_video_frame_rate (best_video_frame_rate());
                        }
@@ -1251,7 +1251,7 @@ Film::signal_change (ChangeType type, Property p)
 
                emit (boost::bind (boost::ref (Change), type, p));
 
-               if (p == Property::VIDEO_FRAME_RATE || p == Property::SEQUENCE) {
+               if (p == FilmProperty::VIDEO_FRAME_RATE || p == FilmProperty::SEQUENCE) {
                        /* We want to call Playlist::maybe_sequence but this must happen after the
                           main signal emission (since the butler will see that emission and un-suspend itself).
                        */
@@ -1334,7 +1334,7 @@ Film::cpls () const
 void
 Film::set_encrypted (bool e)
 {
-       FilmChangeSignaller ch (this, Property::ENCRYPTED);
+       FilmChangeSignaller ch(this, FilmProperty::ENCRYPTED);
        _encrypted = e;
 }
 
@@ -1503,9 +1503,9 @@ void
 Film::playlist_content_change (ChangeType type, weak_ptr<Content> c, int p, bool frequent)
 {
        if (p == ContentProperty::VIDEO_FRAME_RATE) {
-               signal_change (type, Property::CONTENT);
+               signal_change(type, FilmProperty::CONTENT);
        } else if (p == AudioContentProperty::STREAMS) {
-               signal_change (type, Property::NAME);
+               signal_change(type, FilmProperty::NAME);
        }
 
        if (type == ChangeType::DONE) {
@@ -1529,8 +1529,8 @@ Film::playlist_length_change ()
 void
 Film::playlist_change (ChangeType type)
 {
-       signal_change (type, Property::CONTENT);
-       signal_change (type, Property::NAME);
+       signal_change(type, FilmProperty::CONTENT);
+       signal_change(type, FilmProperty::NAME);
 
        if (type == ChangeType::DONE) {
                check_settings_consistency ();
@@ -1595,7 +1595,7 @@ void
 Film::playlist_order_changed ()
 {
        /* XXX: missing PENDING */
-       signal_change (ChangeType::DONE, Property::CONTENT_ORDER);
+       signal_change(ChangeType::DONE, FilmProperty::CONTENT_ORDER);
 }
 
 
@@ -1606,7 +1606,7 @@ Film::set_sequence (bool s)
                return;
        }
 
-       FilmChangeSignaller cc (this, Property::SEQUENCE);
+       FilmChangeSignaller cc(this, FilmProperty::SEQUENCE);
        _sequence = s;
        _playlist->set_sequence (s);
 }
@@ -1956,7 +1956,7 @@ Film::closed_caption_tracks () const
 void
 Film::set_marker (dcp::Marker type, DCPTime time)
 {
-       FilmChangeSignaller ch (this, Property::MARKERS);
+       FilmChangeSignaller ch(this, FilmProperty::MARKERS);
        _markers[type] = time;
 }
 
@@ -1964,7 +1964,7 @@ Film::set_marker (dcp::Marker type, DCPTime time)
 void
 Film::unset_marker (dcp::Marker type)
 {
-       FilmChangeSignaller ch (this, Property::MARKERS);
+       FilmChangeSignaller ch(this, FilmProperty::MARKERS);
        _markers.erase (type);
 }
 
@@ -1972,7 +1972,7 @@ Film::unset_marker (dcp::Marker type)
 void
 Film::clear_markers ()
 {
-       FilmChangeSignaller ch (this, Property::MARKERS);
+       FilmChangeSignaller ch(this, FilmProperty::MARKERS);
        _markers.clear ();
 }
 
@@ -1980,14 +1980,14 @@ Film::clear_markers ()
 void
 Film::set_ratings (vector<dcp::Rating> r)
 {
-       FilmChangeSignaller ch (this, Property::RATINGS);
+       FilmChangeSignaller ch(this, FilmProperty::RATINGS);
        _ratings = r;
 }
 
 void
 Film::set_content_versions (vector<string> v)
 {
-       FilmChangeSignaller ch (this, Property::CONTENT_VERSIONS);
+       FilmChangeSignaller ch(this, FilmProperty::CONTENT_VERSIONS);
        _content_versions = v;
 }
 
@@ -1995,7 +1995,7 @@ Film::set_content_versions (vector<string> v)
 void
 Film::set_name_language (dcp::LanguageTag lang)
 {
-       FilmChangeSignaller ch (this, Property::NAME_LANGUAGE);
+       FilmChangeSignaller ch(this, FilmProperty::NAME_LANGUAGE);
        _name_language = lang;
 }
 
@@ -2003,7 +2003,7 @@ Film::set_name_language (dcp::LanguageTag lang)
 void
 Film::set_release_territory (optional<dcp::LanguageTag::RegionSubtag> region)
 {
-       FilmChangeSignaller ch (this, Property::RELEASE_TERRITORY);
+       FilmChangeSignaller ch(this, FilmProperty::RELEASE_TERRITORY);
        _release_territory = region;
 }
 
@@ -2011,7 +2011,7 @@ Film::set_release_territory (optional<dcp::LanguageTag::RegionSubtag> region)
 void
 Film::set_status (dcp::Status s)
 {
-       FilmChangeSignaller ch (this, Property::STATUS);
+       FilmChangeSignaller ch(this, FilmProperty::STATUS);
        _status = s;
 }
 
@@ -2019,7 +2019,7 @@ Film::set_status (dcp::Status s)
 void
 Film::set_version_number (int v)
 {
-       FilmChangeSignaller ch (this, Property::VERSION_NUMBER);
+       FilmChangeSignaller ch(this, FilmProperty::VERSION_NUMBER);
        _version_number = v;
 }
 
@@ -2027,7 +2027,7 @@ Film::set_version_number (int v)
 void
 Film::set_chain (optional<string> c)
 {
-       FilmChangeSignaller ch (this, Property::CHAIN);
+       FilmChangeSignaller ch(this, FilmProperty::CHAIN);
        _chain = c;
 }
 
@@ -2035,7 +2035,7 @@ Film::set_chain (optional<string> c)
 void
 Film::set_distributor (optional<string> d)
 {
-       FilmChangeSignaller ch (this, Property::DISTRIBUTOR);
+       FilmChangeSignaller ch(this, FilmProperty::DISTRIBUTOR);
        _distributor = d;
 }
 
@@ -2043,7 +2043,7 @@ Film::set_distributor (optional<string> d)
 void
 Film::set_luminance (optional<dcp::Luminance> l)
 {
-       FilmChangeSignaller ch (this, Property::LUMINANCE);
+       FilmChangeSignaller ch(this, FilmProperty::LUMINANCE);
        _luminance = l;
 }
 
@@ -2051,7 +2051,7 @@ Film::set_luminance (optional<dcp::Luminance> l)
 void
 Film::set_facility (optional<string> f)
 {
-       FilmChangeSignaller ch (this, Property::FACILITY);
+       FilmChangeSignaller ch(this, FilmProperty::FACILITY);
        _facility = f;
 }
 
@@ -2059,7 +2059,7 @@ Film::set_facility (optional<string> f)
 void
 Film::set_studio (optional<string> s)
 {
-       FilmChangeSignaller ch (this, Property::STUDIO);
+       FilmChangeSignaller ch(this, FilmProperty::STUDIO);
        _studio = s;
 }
 
@@ -2107,7 +2107,7 @@ Film::add_ffoc_lfoc (Markers& markers) const
 void
 Film::set_temp_version (bool t)
 {
-       FilmChangeSignaller ch (this, Property::TEMP_VERSION);
+       FilmChangeSignaller ch(this, FilmProperty::TEMP_VERSION);
        _temp_version = t;
 }
 
@@ -2115,7 +2115,7 @@ Film::set_temp_version (bool t)
 void
 Film::set_pre_release (bool p)
 {
-       FilmChangeSignaller ch (this, Property::PRE_RELEASE);
+       FilmChangeSignaller ch(this, FilmProperty::PRE_RELEASE);
        _pre_release = p;
 }
 
@@ -2123,7 +2123,7 @@ Film::set_pre_release (bool p)
 void
 Film::set_red_band (bool r)
 {
-       FilmChangeSignaller ch (this, Property::RED_BAND);
+       FilmChangeSignaller ch(this, FilmProperty::RED_BAND);
        _red_band = r;
 }
 
@@ -2131,7 +2131,7 @@ Film::set_red_band (bool r)
 void
 Film::set_two_d_version_of_three_d (bool t)
 {
-       FilmChangeSignaller ch (this, Property::TWO_D_VERSION_OF_THREE_D);
+       FilmChangeSignaller ch(this, FilmProperty::TWO_D_VERSION_OF_THREE_D);
        _two_d_version_of_three_d = t;
 }
 
@@ -2139,7 +2139,7 @@ Film::set_two_d_version_of_three_d (bool t)
 void
 Film::set_audio_language (optional<dcp::LanguageTag> language)
 {
-       FilmChangeSignaller ch (this, Property::AUDIO_LANGUAGE);
+       FilmChangeSignaller ch(this, FilmProperty::AUDIO_LANGUAGE);
        _audio_language = language;
 }
 
@@ -2147,7 +2147,7 @@ Film::set_audio_language (optional<dcp::LanguageTag> language)
 void
 Film::set_audio_frame_rate (int rate)
 {
-       FilmChangeSignaller ch (this, Property::AUDIO_FRAME_RATE);
+       FilmChangeSignaller ch(this, FilmProperty::AUDIO_FRAME_RATE);
        _audio_frame_rate = rate;
 }
 
@@ -2162,7 +2162,7 @@ Film::has_sign_language_video_channel () const
 void
 Film::set_sign_language_video_language (optional<dcp::LanguageTag> lang)
 {
-       FilmChangeSignaller ch (this, Property::SIGN_LANGUAGE_VIDEO_LANGUAGE);
+       FilmChangeSignaller ch(this, FilmProperty::SIGN_LANGUAGE_VIDEO_LANGUAGE);
        _sign_language_video_language = lang;
 }
 
index 958c388b3a7a8d21c3f679dfa8ce006c6791e707..22b58f746a4ddc5602663409ce5ec6eb49b4df34 100644 (file)
@@ -32,6 +32,7 @@
 #include "change_signaller.h"
 #include "dcp_text_track.h"
 #include "dcpomatic_time.h"
+#include "film_property.h"
 #include "frame_rate_change.h"
 #include "named_channel.h"
 #include "resolution.h"
@@ -44,6 +45,7 @@
 #include <dcp/key.h>
 #include <dcp/language_tag.h>
 #include <dcp/rating.h>
+#include <dcp/types.h>
 #include <boost/filesystem.hpp>
 #include <boost/signals2.hpp>
 #include <boost/thread.hpp>
@@ -207,53 +209,6 @@ public:
 
        bool last_written_by_earlier_than(int major, int minor, int micro) const;
 
-       /** Identifiers for the parts of our state; used for signalling changes */
-       enum class Property {
-               NONE,
-               NAME,
-               USE_ISDCF_NAME,
-               /** The playlist's content list has changed (i.e. content has been added or removed) */
-               CONTENT,
-               /** The order of content in the playlist has changed */
-               CONTENT_ORDER,
-               DCP_CONTENT_TYPE,
-               CONTAINER,
-               RESOLUTION,
-               ENCRYPTED,
-               J2K_BANDWIDTH,
-               VIDEO_FRAME_RATE,
-               AUDIO_FRAME_RATE,
-               AUDIO_CHANNELS,
-               /** The setting of _three_d has changed */
-               THREE_D,
-               SEQUENCE,
-               INTEROP,
-               LIMIT_TO_SMPTE_BV20,
-               AUDIO_PROCESSOR,
-               REEL_TYPE,
-               REEL_LENGTH,
-               REENCODE_J2K,
-               MARKERS,
-               RATINGS,
-               CONTENT_VERSIONS,
-               NAME_LANGUAGE,
-               AUDIO_LANGUAGE,
-               RELEASE_TERRITORY,
-               SIGN_LANGUAGE_VIDEO_LANGUAGE,
-               VERSION_NUMBER,
-               STATUS,
-               CHAIN,
-               DISTRIBUTOR,
-               FACILITY,
-               STUDIO,
-               TEMP_VERSION,
-               PRE_RELEASE,
-               RED_BAND,
-               TWO_D_VERSION_OF_THREE_D,
-               LUMINANCE,
-       };
-
-
        /* GET */
 
        boost::optional<boost::filesystem::path> directory () const {
@@ -468,7 +423,7 @@ public:
        void add_ffoc_lfoc (Markers& markers) const;
 
        /** Emitted when some property has of the Film is about to change or has changed */
-       mutable boost::signals2::signal<void (ChangeType, Property)> Change;
+       mutable boost::signals2::signal<void (ChangeType, FilmProperty)> Change;
 
        /** Emitted when some property of our content has changed */
        mutable boost::signals2::signal<void (ChangeType, std::weak_ptr<Content>, int, bool)> ContentChange;
@@ -496,7 +451,7 @@ private:
 
        boost::filesystem::path info_file (dcpomatic::DCPTimePeriod p) const;
 
-       void signal_change (ChangeType, Property);
+       void signal_change (ChangeType, FilmProperty);
        void signal_change (ChangeType, int);
        std::string video_identifier () const;
        void playlist_change (ChangeType);
@@ -606,7 +561,7 @@ private:
 };
 
 
-typedef ChangeSignaller<Film, Film::Property> FilmChangeSignaller;
+typedef ChangeSignaller<Film, FilmProperty> FilmChangeSignaller;
 
 
 #endif
diff --git a/src/lib/film_property.h b/src/lib/film_property.h
new file mode 100644 (file)
index 0000000..55596af
--- /dev/null
@@ -0,0 +1,77 @@
+/*
+    Copyright (C) 2012-2021 Carl Hetherington <cth@carlh.net>
+
+    This file is part of DCP-o-matic.
+
+    DCP-o-matic is free software; you can redistribute it and/or modify
+    it under the terms of the GNU General Public License as published by
+    the Free Software Foundation; either version 2 of the License, or
+    (at your option) any later version.
+
+    DCP-o-matic is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+    GNU General Public License for more details.
+
+    You should have received a copy of the GNU General Public License
+    along with DCP-o-matic.  If not, see <http://www.gnu.org/licenses/>.
+
+*/
+
+
+#ifndef DCPOMATIC_FILM_PROPERTY_H
+#define DCPOMATIC_FILM_PROPERTY_H
+
+
+/** Identifiers for the parts of a Film's state; used for signalling changes.
+ *  This could go in Film but separating it out saves a lot of includes of
+ *  film.h
+ */
+enum class FilmProperty {
+       NONE,
+       NAME,
+       USE_ISDCF_NAME,
+       /** The playlist's content list has changed (i.e. content has been added or removed) */
+       CONTENT,
+       /** The order of content in the playlist has changed */
+       CONTENT_ORDER,
+       DCP_CONTENT_TYPE,
+       CONTAINER,
+       RESOLUTION,
+       ENCRYPTED,
+       J2K_BANDWIDTH,
+       VIDEO_FRAME_RATE,
+       AUDIO_FRAME_RATE,
+       AUDIO_CHANNELS,
+       /** The setting of _three_d has changed */
+       THREE_D,
+       SEQUENCE,
+       INTEROP,
+       LIMIT_TO_SMPTE_BV20,
+       AUDIO_PROCESSOR,
+       REEL_TYPE,
+       REEL_LENGTH,
+       REENCODE_J2K,
+       MARKERS,
+       RATINGS,
+       CONTENT_VERSIONS,
+       NAME_LANGUAGE,
+       AUDIO_LANGUAGE,
+       RELEASE_TERRITORY,
+       SIGN_LANGUAGE_VIDEO_LANGUAGE,
+       VERSION_NUMBER,
+       STATUS,
+       CHAIN,
+       DISTRIBUTOR,
+       FACILITY,
+       STUDIO,
+       TEMP_VERSION,
+       PRE_RELEASE,
+       RED_BAND,
+       TWO_D_VERSION_OF_THREE_D,
+       LUMINANCE,
+};
+
+
+#endif
+
index 067a247208f31b05f7c7cc4f1f6722b1deed09ba..41924735c4635c07d0ad0e484954091c9f248dfa 100644 (file)
@@ -20,6 +20,7 @@
 
 
 #include "decoder.h"
+#include "types.h"
 
 
 class ImageContent;
index 610d7748dd131bd062d812bb3862281850ed5841..40773e2504c3217b1c52fa07caac7434d867c351 100644 (file)
@@ -143,7 +143,7 @@ Player::construct ()
        connect();
        set_video_container_size(film->frame_size());
 
-       film_change (ChangeType::DONE, Film::Property::AUDIO_PROCESSOR);
+       film_change(ChangeType::DONE, FilmProperty::AUDIO_PROCESSOR);
 
        setup_pieces ();
        seek (DCPTime (), true);
@@ -481,7 +481,7 @@ Player::playlist_change (ChangeType type)
 
 
 void
-Player::film_change (ChangeType type, Film::Property p)
+Player::film_change(ChangeType type, FilmProperty p)
 {
        /* Here we should notice Film properties that affect our output, and
           alert listeners that our output now would be different to how it was
@@ -493,9 +493,9 @@ Player::film_change (ChangeType type, Film::Property p)
                return;
        }
 
-       if (p == Film::Property::CONTAINER) {
+       if (p == FilmProperty::CONTAINER) {
                Change (type, PlayerProperty::FILM_CONTAINER, false);
-       } else if (p == Film::Property::VIDEO_FRAME_RATE) {
+       } else if (p == FilmProperty::VIDEO_FRAME_RATE) {
                /* Pieces contain a FrameRateChange which contains the DCP frame rate,
                   so we need new pieces here.
                */
@@ -503,12 +503,12 @@ Player::film_change (ChangeType type, Film::Property p)
                        setup_pieces ();
                }
                Change (type, PlayerProperty::FILM_VIDEO_FRAME_RATE, false);
-       } else if (p == Film::Property::AUDIO_PROCESSOR) {
+       } else if (p == FilmProperty::AUDIO_PROCESSOR) {
                if (type == ChangeType::DONE && film->audio_processor ()) {
                        boost::mutex::scoped_lock lm (_mutex);
                        _audio_processor = film->audio_processor()->clone(film->audio_frame_rate());
                }
-       } else if (p == Film::Property::AUDIO_CHANNELS) {
+       } else if (p == FilmProperty::AUDIO_CHANNELS) {
                if (type == ChangeType::DONE) {
                        boost::mutex::scoped_lock lm (_mutex);
                        _audio_merger.clear ();
index e8f7685213a03313c681bf3d8ab51ef47c8ea0a2..5950b95a39d03ca5b96a1e2b037f150135e0403c 100644 (file)
 #include "content_audio.h"
 #include "content_text.h"
 #include "content_video.h"
+#include "dcp_text_track.h"
 #include "empty.h"
 #include "enum_indexed_vector.h"
-#include "film.h"
+#include "film_property.h"
 #include "image.h"
 #include "player_text.h"
 #include "position_image.h"
@@ -49,6 +50,7 @@ namespace dcp {
 class AtmosContent;
 class AudioBuffers;
 class Content;
+class Film;
 class PlayerVideo;
 class Playlist;
 class ReferencedReelAsset;
@@ -142,7 +144,7 @@ private:
        void construct ();
        void connect();
        void setup_pieces ();
-       void film_change (ChangeType, Film::Property);
+       void film_change(ChangeType, FilmProperty);
        void playlist_change (ChangeType);
        void playlist_content_change (ChangeType, int, bool);
        Frame dcp_to_content_video (std::shared_ptr<const Piece> piece, dcpomatic::DCPTime t) const;
index 51b9963bc02a168d1988120f586b93625faa0769..4ce894afb6364849f61cac057e9c3e03b75b0446 100644 (file)
@@ -20,6 +20,7 @@
 
 
 #include "compose.hpp"
+#include "film.h"
 #include "job.h"
 #include "player.h"
 #include "subtitle_encoder.h"
index 8c570059821d35ca3290dd250524d3f682b2c6f9..be5ab5b953d4544929db1881c64a78ec786d3307 100644 (file)
@@ -54,6 +54,7 @@
 #include "video_content.h"
 #include <dcp/atmos_asset.h>
 #include <dcp/decrypted_kdm.h>
+#include <dcp/file.h>
 #include <dcp/locale_convert.h>
 #include <dcp/picture_asset.h>
 #include <dcp/raw_convert.h>
index 81af93b9ea4b50f7d2fd6db336c183a6ea75ba3d..c4f0e886c3ff43f15a4d43aea7159bd24039e229 100644 (file)
@@ -454,9 +454,9 @@ public:
                _info->triggered_update ();
        }
 
-       void film_changed (ChangeType type, Film::Property property)
+       void film_changed (ChangeType type, FilmProperty property)
        {
-               if (type != ChangeType::DONE || property != Film::Property::CONTENT) {
+               if (type != ChangeType::DONE || property != FilmProperty::CONTENT) {
                        return;
                }
 
index 4cd308ab1cebf852b93d782064f69a5e11d42f02..88377b4e48912656f7e01889424f21976f4c77d6 100644 (file)
@@ -320,13 +320,13 @@ AudioDialog::channel_clicked (wxCommandEvent& ev)
 }
 
 void
-AudioDialog::film_change (ChangeType type, Film::Property p)
+AudioDialog::film_change(ChangeType type, FilmProperty p)
 {
        if (type != ChangeType::DONE) {
                return;
        }
 
-       if (p == Film::Property::AUDIO_CHANNELS) {
+       if (p == FilmProperty::AUDIO_CHANNELS) {
                auto film = _film.lock ();
                if (film) {
                        _channels = film->audio_channels ();
index f0cf0606bbf1b56b02c8d403da74d665f2b11a80..f144fb485ca3bbedd858211d1dae11568448357f 100644 (file)
@@ -21,7 +21,7 @@
 
 #include "lib/audio_analysis.h"
 #include "lib/constants.h"
-#include "lib/film.h"
+#include "lib/film_property.h"
 #include "lib/playlist.h"
 #include <dcp/warnings.h>
 LIBDCP_DISABLE_WARNINGS
@@ -46,7 +46,7 @@ public:
        void set_cursor (boost::optional<dcpomatic::DCPTime> time, boost::optional<float> db);
 
 private:
-       void film_change (ChangeType, Film::Property);
+       void film_change(ChangeType, FilmProperty);
        void content_change (ChangeType, int);
        void channel_clicked (wxCommandEvent &);
        void type_clicked (wxCommandEvent &);
index 50831ec4076607e5833a64d7cc5f983a02ae44c3..f0863431a04b01bebad4feee14b08291c7b74a29 100644 (file)
@@ -34,6 +34,7 @@
 #include "lib/dcp_content.h"
 #include "lib/ffmpeg_audio_stream.h"
 #include "lib/ffmpeg_content.h"
+#include "lib/film.h"
 #include "lib/job_manager.h"
 #include "lib/maths_util.h"
 #include <dcp/warnings.h>
@@ -128,9 +129,9 @@ AudioPanel::create ()
        _delay->wrapped()->SetRange (-1000, 1000);
 
        content_selection_changed ();
-       film_changed (Film::Property::AUDIO_CHANNELS);
-       film_changed (Film::Property::VIDEO_FRAME_RATE);
-       film_changed (Film::Property::REEL_TYPE);
+       film_changed(FilmProperty::AUDIO_CHANNELS);
+       film_changed(FilmProperty::VIDEO_FRAME_RATE);
+       film_changed(FilmProperty::REEL_TYPE);
 
        _reference->bind(&AudioPanel::reference_clicked, this);
        _show->Bind                  (wxEVT_BUTTON,   boost::bind (&AudioPanel::show_clicked, this));
@@ -196,23 +197,23 @@ AudioPanel::add_to_grid ()
 
 
 void
-AudioPanel::film_changed (Film::Property property)
+AudioPanel::film_changed (FilmProperty property)
 {
        if (!_parent->film()) {
                return;
        }
 
        switch (property) {
-       case Film::Property::AUDIO_CHANNELS:
-       case Film::Property::AUDIO_PROCESSOR:
+       case FilmProperty::AUDIO_CHANNELS:
+       case FilmProperty::AUDIO_PROCESSOR:
                _mapping->set_output_channels (_parent->film()->audio_output_names ());
                setup_peak ();
                break;
-       case Film::Property::VIDEO_FRAME_RATE:
+       case FilmProperty::VIDEO_FRAME_RATE:
                setup_description ();
                break;
-       case Film::Property::REEL_TYPE:
-       case Film::Property::INTEROP:
+       case FilmProperty::REEL_TYPE:
+       case FilmProperty::INTEROP:
                setup_sensitivity ();
                break;
        default:
index 5f03de42404811a37b210e685632abf0e044ffac..61dd2783ac8cd54d4ad5e20f8a884490ca7c3ffd 100644 (file)
@@ -41,7 +41,7 @@ public:
        explicit AudioPanel (ContentPanel *);
 
        void create () override;
-       void film_changed (Film::Property) override;
+       void film_changed(FilmProperty) override;
        void film_content_changed (int) override;
        void content_selection_changed () override;
        void set_film (std::shared_ptr<Film>);
index 903d47c7526ce98c36415fa90d74f36e67b68939..d84ea01359966a726773db8ca4a91490bf3b36a3 100644 (file)
@@ -25,6 +25,7 @@
 #include "lib/butler.h"
 #include "lib/compose.hpp"
 #include "lib/constants.h"
+#include "lib/film.h"
 #include "lib/string_text.h"
 #include "lib/text_content.h"
 #include <boost/bind/bind.hpp>
index 0e2dbafb21e9bca274315f52bcdced3888161209..fadcade313494df9da690f14d01835d9766a18e5 100644 (file)
@@ -42,6 +42,7 @@
 #include "lib/dcp_subtitle_decoder.h"
 #include "lib/dcpomatic_log.h"
 #include "lib/ffmpeg_content.h"
+#include "lib/film.h"
 #include "lib/image_content.h"
 #include "lib/log.h"
 #include "lib/playlist.h"
@@ -401,11 +402,11 @@ ContentPanel::selected_ffmpeg ()
 
 
 void
-ContentPanel::film_changed (Film::Property p)
+ContentPanel::film_changed(FilmProperty p)
 {
        switch (p) {
-       case Film::Property::CONTENT:
-       case Film::Property::CONTENT_ORDER:
+       case FilmProperty::CONTENT:
+       case FilmProperty::CONTENT_ORDER:
                setup ();
                break;
        default:
@@ -772,8 +773,8 @@ ContentPanel::set_film (shared_ptr<Film> film)
 
        _film = film;
 
-       film_changed (Film::Property::CONTENT);
-       film_changed (Film::Property::AUDIO_CHANNELS);
+       film_changed(FilmProperty::CONTENT);
+       film_changed(FilmProperty::AUDIO_CHANNELS);
 
        if (_film) {
                check_selection ();
index 88686067221253ea674bf66ef611727cbc101706..6ba9bb1bb00c73a3f853902ab41140ab76bdb6b5 100644 (file)
@@ -21,7 +21,7 @@
 
 #include "content_menu.h"
 #include "lib/enum_indexed_vector.h"
-#include "lib/film.h"
+#include "lib/film_property.h"
 #include "lib/text_type.h"
 #include <dcp/warnings.h>
 LIBDCP_DISABLE_WARNINGS
@@ -67,7 +67,7 @@ public:
        void set_selection (ContentList cl);
        void select_all ();
 
-       void film_changed (Film::Property p);
+       void film_changed(FilmProperty p);
        void film_content_changed (int p);
 
        void first_shown ();
index 2817fab6e939c39f4653ef957ce8cbe4322692b6..a3916817e45f7057fdca651aef5d22097ab65bfb 100644 (file)
 #define DCPOMATIC_CONTENT_SUB_PANEL_H
 
 
-#include "lib/film.h"
+#include "lib/film_property.h"
 #include <dcp/warnings.h>
 LIBDCP_DISABLE_WARNINGS
 #include <wx/wx.h>
 LIBDCP_ENABLE_WARNINGS
+#include <memory>
 
 class ContentPanel;
 class Content;
@@ -42,7 +43,7 @@ public:
 
        virtual void create () = 0;
 
-       virtual void film_changed (Film::Property) {}
+       virtual void film_changed(FilmProperty) {}
        /** Called when a given property of one of the selected Contents changes */
        virtual void film_content_changed (int) = 0;
        /** Called when the list of selected Contents changes */
index 7976a77ced77c4bfa7731ac6178acd1b05a19c01..f8bd7eeb93aabeaeb32e61b78e968ef3c2417c59 100644 (file)
@@ -33,6 +33,7 @@
 #include "lib/cross.h"
 #include "lib/dcp_content.h"
 #include "lib/examine_content_job.h"
+#include "lib/film.h"
 #include "lib/job.h"
 #include "lib/job_manager.h"
 #include "lib/player_video.h"
@@ -430,14 +431,14 @@ Controls::film () const
 
 
 void
-Controls::film_change (ChangeType type, Film::Property p)
+Controls::film_change(ChangeType type, FilmProperty p)
 {
        if (type == ChangeType::DONE) {
-               if (p == Film::Property::CONTENT) {
+               if (p == FilmProperty::CONTENT) {
                        setup_sensitivity ();
                        update_position_label ();
                        update_position_slider ();
-               } else if (p == Film::Property::THREE_D) {
+               } else if (p == FilmProperty::THREE_D) {
                        setup_sensitivity ();
                }
        }
index f0819c51590488065096f5d7276fa2390e7cdced..75bae9bb3877635f50e02f27aa67fdb48baca83f 100644 (file)
@@ -23,8 +23,9 @@
 #define DCPOMATIC_CONTROLS_H
 
 
+#include "lib/change_signaller.h"
 #include "lib/dcpomatic_time.h"
-#include "lib/film.h"
+#include "lib/film_property.h"
 #include <dcp/warnings.h>
 LIBDCP_DISABLE_WARNINGS
 #include <wx/wx.h>
@@ -102,7 +103,7 @@ private:
        void outline_content_changed ();
        void eye_changed ();
        void update_position ();
-       void film_change (ChangeType, Film::Property);
+       void film_change(ChangeType, FilmProperty);
 
        typedef std::pair<std::shared_ptr<dcp::CPL>, boost::filesystem::path> CPL;
 
index 7fc6f00df0ccdb97ac5471580e28ef79ab3aeb7e..1ea5108db572c97e2c0480f526a2db5d8c6339da 100644 (file)
@@ -390,19 +390,19 @@ DCPPanel::metadata_clicked ()
 
 
 void
-DCPPanel::film_changed (Film::Property p)
+DCPPanel::film_changed(FilmProperty p)
 {
        switch (p) {
-       case Film::Property::NONE:
+       case FilmProperty::NONE:
                break;
-       case Film::Property::CONTAINER:
+       case FilmProperty::CONTAINER:
                setup_container ();
                break;
-       case Film::Property::NAME:
+       case FilmProperty::NAME:
                checked_set (_name, _film->name());
                setup_dcp_name ();
                break;
-       case Film::Property::DCP_CONTENT_TYPE:
+       case FilmProperty::DCP_CONTENT_TYPE:
        {
                auto index = DCPContentType::as_index(_film->dcp_content_type());
                DCPOMATIC_ASSERT (index);
@@ -410,18 +410,18 @@ DCPPanel::film_changed (Film::Property p)
                setup_dcp_name ();
                break;
        }
-       case Film::Property::ENCRYPTED:
+       case FilmProperty::ENCRYPTED:
                checked_set (_encrypted, _film->encrypted ());
                break;
-       case Film::Property::RESOLUTION:
+       case FilmProperty::RESOLUTION:
                checked_set (_resolution, _film->resolution() == Resolution::TWO_K ? 0 : 1);
                setup_container ();
                setup_dcp_name ();
                break;
-       case Film::Property::J2K_BANDWIDTH:
+       case FilmProperty::J2K_BANDWIDTH:
                checked_set (_j2k_bandwidth, _film->j2k_bandwidth() / 1000000);
                break;
-       case Film::Property::USE_ISDCF_NAME:
+       case FilmProperty::USE_ISDCF_NAME:
        {
                checked_set (_use_isdcf_name, _film->use_isdcf_name());
                if (_film->use_isdcf_name()) {
@@ -437,7 +437,7 @@ DCPPanel::film_changed (Film::Property p)
                setup_dcp_name ();
                break;
        }
-       case Film::Property::VIDEO_FRAME_RATE:
+       case FilmProperty::VIDEO_FRAME_RATE:
        {
                bool done = false;
                for (unsigned int i = 0; i < _frame_rate_choice->GetCount(); ++i) {
@@ -458,7 +458,7 @@ DCPPanel::film_changed (Film::Property p)
                setup_dcp_name ();
                break;
        }
-       case Film::Property::AUDIO_CHANNELS:
+       case FilmProperty::AUDIO_CHANNELS:
                if (_film->audio_channels() < minimum_allowed_audio_channels()) {
                        _film->set_audio_channels (minimum_allowed_audio_channels());
                } else {
@@ -466,42 +466,42 @@ DCPPanel::film_changed (Film::Property p)
                        setup_dcp_name ();
                }
                break;
-       case Film::Property::THREE_D:
+       case FilmProperty::THREE_D:
                checked_set (_three_d, _film->three_d());
                setup_dcp_name ();
                break;
-       case Film::Property::REENCODE_J2K:
+       case FilmProperty::REENCODE_J2K:
                checked_set (_reencode_j2k, _film->reencode_j2k());
                break;
-       case Film::Property::INTEROP:
+       case FilmProperty::INTEROP:
                set_standard();
                setup_dcp_name ();
                _markers->Enable (!_film->interop());
                break;
-       case Film::Property::LIMIT_TO_SMPTE_BV20:
+       case FilmProperty::LIMIT_TO_SMPTE_BV20:
                set_standard();
                break;
-       case Film::Property::AUDIO_PROCESSOR:
+       case FilmProperty::AUDIO_PROCESSOR:
                if (_film->audio_processor()) {
                        checked_set (_audio_processor, _film->audio_processor()->id());
                } else {
                        checked_set (_audio_processor, 0);
                }
                setup_audio_channels_choice (_audio_channels, minimum_allowed_audio_channels());
-               film_changed (Film::Property::AUDIO_CHANNELS);
+               film_changed (FilmProperty::AUDIO_CHANNELS);
                break;
-       case Film::Property::REEL_TYPE:
+       case FilmProperty::REEL_TYPE:
                checked_set (_reel_type, static_cast<int>(_film->reel_type()));
                _reel_length->Enable (_film->reel_type() == ReelType::BY_LENGTH);
                break;
-       case Film::Property::REEL_LENGTH:
+       case FilmProperty::REEL_LENGTH:
                checked_set (_reel_length, _film->reel_length() / 1000000000LL);
                break;
-       case Film::Property::CONTENT:
+       case FilmProperty::CONTENT:
                setup_dcp_name ();
                setup_sensitivity ();
                break;
-       case Film::Property::AUDIO_LANGUAGE:
+       case FilmProperty::AUDIO_LANGUAGE:
        {
                auto al = _film->audio_language();
                checked_set (_enable_audio_language, static_cast<bool>(al));
@@ -510,23 +510,23 @@ DCPPanel::film_changed (Film::Property p)
                setup_sensitivity ();
                break;
        }
-       case Film::Property::AUDIO_FRAME_RATE:
+       case FilmProperty::AUDIO_FRAME_RATE:
                if (_audio_sample_rate) {
                        checked_set (_audio_sample_rate, _film->audio_frame_rate() == 48000 ? 0 : 1);
                }
                break;
-       case Film::Property::CONTENT_VERSIONS:
-       case Film::Property::VERSION_NUMBER:
-       case Film::Property::RELEASE_TERRITORY:
-       case Film::Property::RATINGS:
-       case Film::Property::FACILITY:
-       case Film::Property::STUDIO:
-       case Film::Property::TEMP_VERSION:
-       case Film::Property::PRE_RELEASE:
-       case Film::Property::RED_BAND:
-       case Film::Property::TWO_D_VERSION_OF_THREE_D:
-       case Film::Property::CHAIN:
-       case Film::Property::LUMINANCE:
+       case FilmProperty::CONTENT_VERSIONS:
+       case FilmProperty::VERSION_NUMBER:
+       case FilmProperty::RELEASE_TERRITORY:
+       case FilmProperty::RATINGS:
+       case FilmProperty::FACILITY:
+       case FilmProperty::STUDIO:
+       case FilmProperty::TEMP_VERSION:
+       case FilmProperty::PRE_RELEASE:
+       case FilmProperty::RED_BAND:
+       case FilmProperty::TWO_D_VERSION_OF_THREE_D:
+       case FilmProperty::CHAIN:
+       case FilmProperty::LUMINANCE:
                setup_dcp_name ();
                break;
        default:
@@ -631,26 +631,26 @@ DCPPanel::set_film (shared_ptr<Film> film)
        _standard->Clear();
        add_standards();
 
-       film_changed (Film::Property::NAME);
-       film_changed (Film::Property::USE_ISDCF_NAME);
-       film_changed (Film::Property::CONTENT);
-       film_changed (Film::Property::DCP_CONTENT_TYPE);
-       film_changed (Film::Property::CONTAINER);
-       film_changed (Film::Property::RESOLUTION);
-       film_changed (Film::Property::ENCRYPTED);
-       film_changed (Film::Property::J2K_BANDWIDTH);
-       film_changed (Film::Property::VIDEO_FRAME_RATE);
-       film_changed (Film::Property::AUDIO_CHANNELS);
-       film_changed (Film::Property::SEQUENCE);
-       film_changed (Film::Property::THREE_D);
-       film_changed (Film::Property::INTEROP);
-       film_changed (Film::Property::AUDIO_PROCESSOR);
-       film_changed (Film::Property::REEL_TYPE);
-       film_changed (Film::Property::REEL_LENGTH);
-       film_changed (Film::Property::REENCODE_J2K);
-       film_changed (Film::Property::AUDIO_LANGUAGE);
-       film_changed (Film::Property::AUDIO_FRAME_RATE);
-       film_changed (Film::Property::LIMIT_TO_SMPTE_BV20);
+       film_changed(FilmProperty::NAME);
+       film_changed(FilmProperty::USE_ISDCF_NAME);
+       film_changed(FilmProperty::CONTENT);
+       film_changed(FilmProperty::DCP_CONTENT_TYPE);
+       film_changed(FilmProperty::CONTAINER);
+       film_changed(FilmProperty::RESOLUTION);
+       film_changed(FilmProperty::ENCRYPTED);
+       film_changed(FilmProperty::J2K_BANDWIDTH);
+       film_changed(FilmProperty::VIDEO_FRAME_RATE);
+       film_changed(FilmProperty::AUDIO_CHANNELS);
+       film_changed(FilmProperty::SEQUENCE);
+       film_changed(FilmProperty::THREE_D);
+       film_changed(FilmProperty::INTEROP);
+       film_changed(FilmProperty::AUDIO_PROCESSOR);
+       film_changed(FilmProperty::REEL_TYPE);
+       film_changed(FilmProperty::REEL_LENGTH);
+       film_changed(FilmProperty::REENCODE_J2K);
+       film_changed(FilmProperty::AUDIO_LANGUAGE);
+       film_changed(FilmProperty::AUDIO_FRAME_RATE);
+       film_changed(FilmProperty::LIMIT_TO_SMPTE_BV20);
 
        set_general_sensitivity(static_cast<bool>(_film));
 }
@@ -769,14 +769,14 @@ DCPPanel::config_changed (Config::Property p)
                _audio_processor->Clear ();
                add_audio_processors ();
                if (_film) {
-                       film_changed (Film::Property::AUDIO_PROCESSOR);
+                       film_changed(FilmProperty::AUDIO_PROCESSOR);
                }
        } else if (p == Config::ALLOW_SMPTE_BV20) {
                _standard->Clear();
                add_standards();
                if (_film) {
-                       film_changed(Film::Property::INTEROP);
-                       film_changed(Film::Property::LIMIT_TO_SMPTE_BV20);
+                       film_changed(FilmProperty::INTEROP);
+                       film_changed(FilmProperty::LIMIT_TO_SMPTE_BV20);
                }
        } else if (p == Config::ISDCF_NAME_PART_LENGTH) {
                setup_dcp_name();
index 6635d4a2980ab5066ba85fe53550fbe399dc817a..849fe185cf836bc588428c9308dd928db014226b 100644 (file)
@@ -21,7 +21,7 @@
 
 #include "wx_ptr.h"
 #include "lib/config.h"
-#include "lib/film.h"
+#include "lib/film_property.h"
 
 
 class Button;
@@ -57,7 +57,7 @@ public:
        void set_film (std::shared_ptr<Film>);
        void set_general_sensitivity (bool);
 
-       void film_changed (Film::Property);
+       void film_changed(FilmProperty);
        void film_content_changed (int);
 
        wxPanel* panel () const {
index e602f9333ca40bb9b65fd0aff1d9bbdac9038e5d..9f54db58e027e9b651f830d098d41045c0e91775 100644 (file)
@@ -76,7 +76,7 @@ FilmEditor::FilmEditor(wxWindow* parent, FilmViewer& viewer)
  *  @param p Property of the Film that has changed.
  */
 void
-FilmEditor::film_change (ChangeType type, Film::Property p)
+FilmEditor::film_change(ChangeType type, FilmProperty p)
 {
        if (type != ChangeType::DONE) {
                return;
@@ -91,7 +91,7 @@ FilmEditor::film_change (ChangeType type, Film::Property p)
        _content_panel->film_changed (p);
        _dcp_panel->film_changed (p);
 
-       if (p == Film::Property::CONTENT && !_film->content().empty()) {
+       if (p == FilmProperty::CONTENT && !_film->content().empty()) {
                /* Select newly-added content */
                _content_panel->set_selection (_film->content().back ());
        }
index 296058c212e55ee7496ec589e53ac2eaca51e4d0..a3df266adfd311933f44d37dd46f4d340dd2bff1 100644 (file)
@@ -24,7 +24,7 @@
  */
 
 
-#include "lib/film.h"
+#include "lib/film_property.h"
 #include <dcp/warnings.h>
 LIBDCP_DISABLE_WARNINGS
 #include <wx/wx.h>
@@ -65,7 +65,7 @@ public:
 private:
 
        /* Handle changes to the model */
-       void film_change (ChangeType, Film::Property);
+       void film_change(ChangeType, FilmProperty);
        void film_content_change (ChangeType type, int);
 
        void set_general_sensitivity (bool);
index e7dcf564230e29ada4f907d8bdfa408d14a312e7..72193fbadb8e76e6651b1681d2bf5dd0fd35c106 100644 (file)
@@ -189,8 +189,8 @@ FilmViewer::set_film (shared_ptr<Film> film)
        _film->LengthChange.connect (boost::bind(&FilmViewer::film_length_change, this));
        _player->Change.connect (boost::bind (&FilmViewer::player_change, this, _1, _2, _3));
 
-       film_change (ChangeType::DONE, Film::Property::VIDEO_FRAME_RATE);
-       film_change (ChangeType::DONE, Film::Property::THREE_D);
+       film_change(ChangeType::DONE, FilmProperty::VIDEO_FRAME_RATE);
+       film_change(ChangeType::DONE, FilmProperty::THREE_D);
        film_length_change ();
 
        /* Keep about 1 second's worth of history samples */
@@ -486,19 +486,19 @@ FilmViewer::player_change (vector<int> properties)
 
 
 void
-FilmViewer::film_change (ChangeType type, Film::Property p)
+FilmViewer::film_change(ChangeType type, FilmProperty p)
 {
        if (type != ChangeType::DONE) {
                return;
        }
 
-       if (p == Film::Property::AUDIO_CHANNELS) {
+       if (p == FilmProperty::AUDIO_CHANNELS) {
                destroy_and_maybe_create_butler();
-       } else if (p == Film::Property::VIDEO_FRAME_RATE) {
+       } else if (p == FilmProperty::VIDEO_FRAME_RATE) {
                _video_view->set_video_frame_rate (_film->video_frame_rate());
-       } else if (p == Film::Property::THREE_D) {
+       } else if (p == FilmProperty::THREE_D) {
                _video_view->set_three_d (_film->three_d());
-       } else if (p == Film::Property::CONTENT) {
+       } else if (p == FilmProperty::CONTENT) {
                _closed_captions_dialog->update_tracks (_film);
        }
 }
index aea3f8c8633465933af11c5e5ccad26610d87d4d..0442dac715cbfdef47f26678e1772572be69a588 100644 (file)
@@ -26,7 +26,7 @@
 
 #include "video_view.h"
 #include "lib/config.h"
-#include "lib/film.h"
+#include "lib/film_property.h"
 #include "lib/player_text.h"
 #include "lib/signaller.h"
 #include "lib/timer.h"
@@ -162,7 +162,7 @@ private:
        void player_change (std::vector<int> properties);
        void idle_handler ();
        void request_idle_display_next_frame ();
-       void film_change (ChangeType, Film::Property);
+       void film_change(ChangeType, FilmProperty);
        void destroy_butler();
        void create_butler();
        void destroy_and_maybe_create_butler();
index 964f6f1ab9db2db8469e1fce8a36bd2d93279fa3..69de7b76fdbcd4e9555113327ebe92259d2c358b 100644 (file)
@@ -25,6 +25,10 @@ LIBDCP_DISABLE_WARNINGS
 #include <wx/wx.h>
 LIBDCP_ENABLE_WARNINGS
 
+#undef None
+#undef Success
+#undef Status
+
 
 /* The OpenGL API in wxWidgets 3.0.x is sufficiently different to make it awkward to support,
  * and I think it may even have things missing that we require (e.g. the attributes parameter
@@ -34,6 +38,7 @@ LIBDCP_ENABLE_WARNINGS
  */
 #if wxCHECK_VERSION(3,1,0)
 
+
 #include "video_view.h"
 #include "lib/signaller.h"
 #include "lib/position.h"
@@ -41,9 +46,6 @@ LIBDCP_ENABLE_WARNINGS
 #include <boost/atomic.hpp>
 #include <boost/thread.hpp>
 #include <boost/thread/condition.hpp>
-#undef None
-#undef Success
-#undef Status
 
 
 class Texture
index 9942dca8993d9d61d7beafc2733b059bd68bcf78..463f06758f1aae7575f82f9a54eb88767012e90a 100644 (file)
@@ -23,6 +23,7 @@
 #include "markers.h"
 #include "markers_panel.h"
 #include "wx_util.h"
+#include "lib/film.h"
 #include <dcp/warnings.h>
 LIBDCP_DISABLE_WARNINGS
 #include <wx/graphics.h>
@@ -82,7 +83,7 @@ MarkersPanel::set_film (weak_ptr<Film> weak_film)
 
 
 void
-MarkersPanel::film_changed (ChangeType type, Film::Property property)
+MarkersPanel::film_changed(ChangeType type, FilmProperty property)
 {
        if (type != ChangeType::DONE) {
                return;
@@ -93,7 +94,7 @@ MarkersPanel::film_changed (ChangeType type, Film::Property property)
                return;
        }
 
-       if (property == Film::Property::MARKERS || property == Film::Property::CONTENT || property == Film::Property::CONTENT_ORDER || property == Film::Property::VIDEO_FRAME_RATE) {
+       if (property == FilmProperty::MARKERS || property == FilmProperty::CONTENT || property == FilmProperty::CONTENT_ORDER || property == FilmProperty::VIDEO_FRAME_RATE) {
                update_from_film (film);
        }
 }
index e34008a41fc5c0e4c29c9ef355ef1496e5fd2216..3f43ee7d2662c9ae855299ff8e6ff8234ac31f79 100644 (file)
@@ -20,7 +20,7 @@
 
 
 #include "lib/dcpomatic_time.h"
-#include "lib/film.h"
+#include "lib/film_property.h"
 #include <dcp/warnings.h>
 LIBDCP_DISABLE_WARNINGS
 #include <wx/wx.h>
@@ -47,7 +47,7 @@ private:
        void move_marker_to_current_position ();
        void remove_marker ();
        void add_marker (wxCommandEvent& ev);
-       void film_changed (ChangeType type, Film::Property property);
+       void film_changed(ChangeType type, FilmProperty property);
        void update_from_film (std::shared_ptr<Film> film);
 
        wxTipWindow* _tip = nullptr;
index e9a3b1af98baefbc2c1cb45c90d00606ae6a38a3..df92cef6304a68936bccab203c49eb90808ee756 100644 (file)
@@ -30,6 +30,7 @@
 #include "region_subtag_widget.h"
 #include "wx_util.h"
 #include "lib/film.h"
+#include "lib/film_property.h"
 #include <dcp/warnings.h>
 LIBDCP_DISABLE_WARNINGS
 #include <wx/notebook.h>
@@ -105,61 +106,61 @@ MetadataDialog::setup ()
 
        _film_changed_connection = film()->Change.connect(boost::bind(&MetadataDialog::film_changed, this, _1, _2));
 
-       film_changed (ChangeType::DONE, Film::Property::RELEASE_TERRITORY);
-       film_changed (ChangeType::DONE, Film::Property::SIGN_LANGUAGE_VIDEO_LANGUAGE);
-       film_changed (ChangeType::DONE, Film::Property::FACILITY);
-       film_changed (ChangeType::DONE, Film::Property::STUDIO);
-       film_changed (ChangeType::DONE, Film::Property::TEMP_VERSION);
-       film_changed (ChangeType::DONE, Film::Property::PRE_RELEASE);
-       film_changed (ChangeType::DONE, Film::Property::RED_BAND);
-       film_changed (ChangeType::DONE, Film::Property::TWO_D_VERSION_OF_THREE_D);
-       film_changed (ChangeType::DONE, Film::Property::CHAIN);
-       film_changed (ChangeType::DONE, Film::Property::LUMINANCE);
+       film_changed(ChangeType::DONE, FilmProperty::RELEASE_TERRITORY);
+       film_changed(ChangeType::DONE, FilmProperty::SIGN_LANGUAGE_VIDEO_LANGUAGE);
+       film_changed(ChangeType::DONE, FilmProperty::FACILITY);
+       film_changed(ChangeType::DONE, FilmProperty::STUDIO);
+       film_changed(ChangeType::DONE, FilmProperty::TEMP_VERSION);
+       film_changed(ChangeType::DONE, FilmProperty::PRE_RELEASE);
+       film_changed(ChangeType::DONE, FilmProperty::RED_BAND);
+       film_changed(ChangeType::DONE, FilmProperty::TWO_D_VERSION_OF_THREE_D);
+       film_changed(ChangeType::DONE, FilmProperty::CHAIN);
+       film_changed(ChangeType::DONE, FilmProperty::LUMINANCE);
 
        setup_sensitivity ();
 }
 
 
 void
-MetadataDialog::film_changed (ChangeType type, Film::Property property)
+MetadataDialog::film_changed(ChangeType type, FilmProperty property)
 {
        if (type != ChangeType::DONE) {
                return;
        }
 
-       if (property == Film::Property::SIGN_LANGUAGE_VIDEO_LANGUAGE) {
+       if (property == FilmProperty::SIGN_LANGUAGE_VIDEO_LANGUAGE) {
                _sign_language_video_language->set (film()->sign_language_video_language());
-       } else if (property == Film::Property::RELEASE_TERRITORY) {
+       } else if (property == FilmProperty::RELEASE_TERRITORY) {
                auto rt = film()->release_territory();
                checked_set (_enable_release_territory, static_cast<bool>(rt));
                if (rt) {
                        _release_territory_copy = *rt;
                        checked_set(_release_territory, *_release_territory_copy);
                }
-       } else if (property == Film::Property::FACILITY) {
+       } else if (property == FilmProperty::FACILITY) {
                checked_set (_enable_facility, static_cast<bool>(film()->facility()));
                if (film()->facility()) {
                        checked_set (_facility, *film()->facility());
                }
-       } else if (property == Film::Property::STUDIO) {
+       } else if (property == FilmProperty::STUDIO) {
                checked_set (_enable_studio, static_cast<bool>(film()->studio()));
                if (film()->studio()) {
                        checked_set (_studio, *film()->studio());
                }
-       } else if (property == Film::Property::CHAIN) {
+       } else if (property == FilmProperty::CHAIN) {
                checked_set (_enable_chain, static_cast<bool>(film()->chain()));
                if (film()->chain()) {
                        checked_set (_chain, *film()->chain());
                }
-       } else if (property == Film::Property::TEMP_VERSION) {
+       } else if (property == FilmProperty::TEMP_VERSION) {
                checked_set (_temp_version, film()->temp_version());
-       } else if (property == Film::Property::PRE_RELEASE) {
+       } else if (property == FilmProperty::PRE_RELEASE) {
                checked_set (_pre_release, film()->pre_release());
-       } else if (property == Film::Property::RED_BAND) {
+       } else if (property == FilmProperty::RED_BAND) {
                checked_set (_red_band, film()->red_band());
-       } else if (property == Film::Property::TWO_D_VERSION_OF_THREE_D) {
+       } else if (property == FilmProperty::TWO_D_VERSION_OF_THREE_D) {
                checked_set (_two_d_version_of_three_d, film()->two_d_version_of_three_d());
-       } else if (property == Film::Property::LUMINANCE) {
+       } else if (property == FilmProperty::LUMINANCE) {
                auto lum = film()->luminance();
                checked_set (_enable_luminance, static_cast<bool>(lum));
                if (lum) {
index b77b14a996216746d37d719834f3e78eba425df2..43da2ba717f344372155cb1329c6b05878db8760 100644 (file)
@@ -25,8 +25,9 @@
 
 #include "editable_list.h"
 #include "lib/change_signaller.h"
-#include "lib/film.h"
+#include "lib/film_property.h"
 #include "lib/weak_film.h"
+#include <dcp/rating.h>
 #include <dcp/warnings.h>
 LIBDCP_DISABLE_WARNINGS
 #include <wx/wx.h>
@@ -53,7 +54,7 @@ public:
 protected:
        virtual void setup_standard (wxPanel*, wxSizer*);
        virtual void setup_advanced (wxPanel*, wxSizer*);
-       virtual void film_changed (ChangeType type, Film::Property property);
+       virtual void film_changed(ChangeType type, FilmProperty property);
        virtual void setup_sensitivity ();
 
        EditableList<dcp::Rating, RatingDialog>* _ratings;
index 8d67cd99899a3aaca9539df928bf00e62817d489..11136d1238e7cca90c7b8c23bb0119a0d3f90946 100644 (file)
@@ -30,6 +30,7 @@
 #include "lib/cross.h"
 #include "lib/dcp_content.h"
 #include "lib/ffmpeg_content.h"
+#include "lib/film.h"
 #include "lib/internet.h"
 #include "lib/player_video.h"
 #include "lib/scoped_temporary.h"
index f5d63e329be924085f39c96043e0771993b600a1..8471199bdf590e7a4591f02e67dfcc7908c0fb59 100644 (file)
@@ -142,18 +142,18 @@ SMPTEMetadataDialog::setup ()
        _enable_distributor->bind(&SMPTEMetadataDialog::enable_distributor_changed, this);
        _distributor->Bind (wxEVT_TEXT, boost::bind(&SMPTEMetadataDialog::distributor_changed, this));
 
-       film_changed (ChangeType::DONE, Film::Property::NAME_LANGUAGE);
-       film_changed (ChangeType::DONE, Film::Property::VERSION_NUMBER);
-       film_changed (ChangeType::DONE, Film::Property::STATUS);
-       film_changed (ChangeType::DONE, Film::Property::DISTRIBUTOR);
-       film_changed (ChangeType::DONE, Film::Property::CONTENT_VERSIONS);
+       film_changed(ChangeType::DONE, FilmProperty::NAME_LANGUAGE);
+       film_changed(ChangeType::DONE, FilmProperty::VERSION_NUMBER);
+       film_changed(ChangeType::DONE, FilmProperty::STATUS);
+       film_changed(ChangeType::DONE, FilmProperty::DISTRIBUTOR);
+       film_changed(ChangeType::DONE, FilmProperty::CONTENT_VERSIONS);
 
        setup_sensitivity ();
 }
 
 
 void
-SMPTEMetadataDialog::film_changed (ChangeType type, Film::Property property)
+SMPTEMetadataDialog::film_changed(ChangeType type, FilmProperty property)
 {
        MetadataDialog::film_changed (type, property);
 
@@ -161,11 +161,11 @@ SMPTEMetadataDialog::film_changed (ChangeType type, Film::Property property)
                return;
        }
 
-       if (property == Film::Property::NAME_LANGUAGE) {
+       if (property == FilmProperty::NAME_LANGUAGE) {
                _name_language->set (film()->name_language());
-       } else if (property == Film::Property::VERSION_NUMBER) {
+       } else if (property == FilmProperty::VERSION_NUMBER) {
                checked_set (_version_number, film()->version_number());
-       } else if (property == Film::Property::STATUS) {
+       } else if (property == FilmProperty::STATUS) {
                switch (film()->status()) {
                case dcp::Status::TEMP:
                        checked_set (_status, 0);
@@ -177,7 +177,7 @@ SMPTEMetadataDialog::film_changed (ChangeType type, Film::Property property)
                        checked_set (_status, 2);
                        break;
                }
-       } else if (property == Film::Property::DISTRIBUTOR) {
+       } else if (property == FilmProperty::DISTRIBUTOR) {
                checked_set (_enable_distributor, static_cast<bool>(film()->distributor()));
                if (film()->distributor()) {
                        checked_set (_distributor, *film()->distributor());
index b6301e88315ae50149de1795e596aa9c0374a8f3..4ac943f7a6df8b8a60a29e0faca1a22c45d43b77 100644 (file)
@@ -22,8 +22,7 @@
 #include "editable_list.h"
 #include "full_language_tag_dialog.h"
 #include "metadata_dialog.h"
-#include "lib/film.h"
-#include "lib/weak_film.h"
+#include "lib/film_property.h"
 #include <dcp/language_tag.h>
 #include <dcp/types.h>
 #include <dcp/warnings.h>
@@ -49,7 +48,7 @@ public:
 private:
        void setup_standard (wxPanel* parent, wxSizer* sizer) override;
        void setup_advanced (wxPanel* parent, wxSizer* sizer) override;
-       void film_changed (ChangeType type, Film::Property property) override;
+       void film_changed(ChangeType type, FilmProperty property) override;
        void setup_sensitivity () override;
 
        std::vector<std::string> content_versions () const;
index de63c2fce8da83ab32e74aa6708ff3eca3c07960..942c49fc4baf5b3d9fe1325c718efd8cd397d813 100644 (file)
@@ -21,6 +21,7 @@
 
 #include "film_viewer.h"
 #include "standard_controls.h"
+#include "lib/film.h"
 #include <dcp/warnings.h>
 LIBDCP_DISABLE_WARNINGS
 #include <wx/tglbtn.h>
index 805af2c238fa727dcc5fd4495bce235e0151c6d9..ff4e26a574fde15398a5ef5465d06ddc8178e404 100644 (file)
@@ -40,6 +40,7 @@
 #include "lib/decoder_factory.h"
 #include "lib/ffmpeg_content.h"
 #include "lib/ffmpeg_subtitle_stream.h"
+#include "lib/film.h"
 #include "lib/job_manager.h"
 #include "lib/scope_guard.h"
 #include "lib/string_text_file_content.h"
@@ -400,9 +401,9 @@ TextPanel::dcp_track_changed ()
 
 
 void
-TextPanel::film_changed (Film::Property property)
+TextPanel::film_changed(FilmProperty property)
 {
-       if (property == Film::Property::CONTENT || property == Film::Property::REEL_TYPE || property == Film::Property::INTEROP) {
+       if (property == FilmProperty::CONTENT || property == FilmProperty::REEL_TYPE || property == FilmProperty::INTEROP) {
                setup_sensitivity ();
        }
 }
index eee5e916cb50248f9e48713d269fb77c70850101..5adad5a3ed14dd55fb05579d1586fff7c2840615 100644 (file)
@@ -19,6 +19,7 @@
 */
 
 
+#include "lib/job.h"
 #include "content_sub_panel.h"
 #include "wx_ptr.h"
 
@@ -38,7 +39,7 @@ public:
        TextPanel (ContentPanel *, TextType t);
 
        void create () override;
-       void film_changed (Film::Property) override;
+       void film_changed(FilmProperty) override;
        void film_content_changed (int) override;
        void content_selection_changed () override;
 
index c6ce1527b0aaa549fc9690f781ddc40e24ba1f3e..95e48f562a8c145a29c0c60fe1b2351e07e6c6cc 100644 (file)
@@ -117,7 +117,7 @@ Timeline::Timeline(wxWindow* parent, ContentPanel* cp, shared_ptr<Film> film, Fi
        _main_canvas->Bind   (wxEVT_SCROLLWIN_PAGEDOWN,   boost::bind (&Timeline::scrolled,     this, _1));
        _main_canvas->Bind   (wxEVT_SCROLLWIN_THUMBTRACK, boost::bind (&Timeline::scrolled,     this, _1));
 
-       film_change (ChangeType::DONE, Film::Property::CONTENT);
+       film_change(ChangeType::DONE, FilmProperty::CONTENT);
 
        SetMinSize (wxSize (640, 4 * pixels_per_track() + 96));
 
@@ -237,16 +237,16 @@ Timeline::paint_main ()
 
 
 void
-Timeline::film_change (ChangeType type, Film::Property p)
+Timeline::film_change(ChangeType type, FilmProperty p)
 {
        if (type != ChangeType::DONE) {
                return;
        }
 
-       if (p == Film::Property::CONTENT || p == Film::Property::REEL_TYPE || p == Film::Property::REEL_LENGTH) {
+       if (p == FilmProperty::CONTENT || p == FilmProperty::REEL_TYPE || p == FilmProperty::REEL_LENGTH) {
                ensure_ui_thread ();
                recreate_views ();
-       } else if (p == Film::Property::CONTENT_ORDER) {
+       } else if (p == FilmProperty::CONTENT_ORDER) {
                Refresh ();
        }
 }
index 184a5d9ee743e95b7f95e575108be7fc4a72879c..2485e835fa8e4faa235d605d53371d5a09d8d5e7 100644 (file)
@@ -21,7 +21,7 @@
 
 #include "content_menu.h"
 #include "timeline_content_view.h"
-#include "lib/film.h"
+#include "lib/film_property.h"
 #include "lib/rect.h"
 #include <dcp/warnings.h>
 LIBDCP_DISABLE_WARNINGS
@@ -97,7 +97,7 @@ private:
        void mouse_moved (wxMouseEvent &);
        void mouse_moved_select (wxMouseEvent &);
        void mouse_moved_zoom (wxMouseEvent &);
-       void film_change (ChangeType type, Film::Property);
+       void film_change(ChangeType type, FilmProperty);
        void film_content_change (ChangeType type, int, bool frequent);
        void resized ();
        void assign_tracks ();
index d6c784387435111edb560b68667b03aa292a80bc..e0e1689a8acfcf227e89ab5ff78ff822dbb601c6 100644 (file)
@@ -25,6 +25,7 @@
 #include "wx_util.h"
 #include "lib/compose.hpp"
 #include "lib/cross.h"
+#include "lib/film.h"
 #include "lib/playlist.h"
 #include <dcp/warnings.h>
 LIBDCP_DISABLE_WARNINGS
@@ -98,14 +99,14 @@ TimelineDialog::TimelineDialog(ContentPanel* cp, shared_ptr<Film> film, FilmView
        Bind(wxEVT_CHAR_HOOK, boost::bind(&TimelineDialog::keypress, this, _1));
 
         _toolbar->ToggleTool ((int) Timeline::SNAP, _timeline.snap ());
-       film_change (ChangeType::DONE, Film::Property::SEQUENCE);
+       film_change(ChangeType::DONE, FilmProperty::SEQUENCE);
 
        _film_changed_connection = film->Change.connect (bind (&TimelineDialog::film_change, this, _1, _2));
 }
 
 
 void
-TimelineDialog::film_change (ChangeType type, Film::Property p)
+TimelineDialog::film_change(ChangeType type, FilmProperty p)
 {
        if (type != ChangeType::DONE) {
                return;
@@ -116,7 +117,7 @@ TimelineDialog::film_change (ChangeType type, Film::Property p)
                return;
        }
 
-       if (p == Film::Property::SEQUENCE) {
+       if (p == FilmProperty::SEQUENCE) {
                _toolbar->ToggleTool ((int) Timeline::SEQUENCE, film->sequence ());
        }
 }
index 155d51fac4b0289d134f4459e26cea905e9d5b7c..8134aa6dbae15c34503237eb5e16d0d1fda9c155 100644 (file)
@@ -37,7 +37,7 @@ public:
        void set_selection (ContentList selection);
 
 private:
-       void film_change (ChangeType type, Film::Property);
+       void film_change(ChangeType type, FilmProperty);
        void tool_clicked (wxCommandEvent& id);
        void keypress(wxKeyEvent const& event);
 
index 2ec8f9e8283c06c7008c5a2e51564d9af3f5c339..0601a1196a1ee77a7aa1d52281182200d11af25b 100644 (file)
@@ -22,6 +22,7 @@
 #include "timeline.h"
 #include "timeline_reels_view.h"
 #include "wx_util.h"
+#include "lib/film.h"
 #include <dcp/warnings.h>
 LIBDCP_DISABLE_WARNINGS
 #include <wx/graphics.h>
index 890049ae92826657d66e5a602c8e6aa4787ab04b..98060bb87322c0a64122d4587a469917fbf67e08 100644 (file)
@@ -32,6 +32,7 @@
 #include "lib/dcp_content.h"
 #include "lib/dcp_subtitle_content.h"
 #include "lib/ffmpeg_content.h"
+#include "lib/film.h"
 #include "lib/image_content.h"
 #include "lib/scope_guard.h"
 #include "lib/string_text_file_content.h"
@@ -421,9 +422,9 @@ TimingPanel::content_selection_changed ()
 }
 
 void
-TimingPanel::film_changed (Film::Property p)
+TimingPanel::film_changed(FilmProperty p)
 {
-       if (p == Film::Property::VIDEO_FRAME_RATE) {
+       if (p == FilmProperty::VIDEO_FRAME_RATE) {
                update_full_length ();
                update_play_length ();
        }
index 1edaeb27192b18da2f4195b9639676ab878b170b..13e733be69d318b0e4afd0b20e829cb608c171bf 100644 (file)
@@ -30,7 +30,7 @@ public:
        TimingPanel(ContentPanel *, FilmViewer& viewer);
 
        void create () override;
-       void film_changed (Film::Property) override;
+       void film_changed(FilmProperty) override;
        void film_content_changed (int) override;
        void content_selection_changed () override;
 
index 4f7c2db791400d8038efed8ab81499e69d5b6061..a9ef6e02dea1d36f051d774d94ae988dac86f966 100644 (file)
@@ -33,6 +33,7 @@
 #include "lib/config.h"
 #include "lib/dcp_content.h"
 #include "lib/ffmpeg_content.h"
+#include "lib/film.h"
 #include "lib/filter.h"
 #include "lib/frame_rate_change.h"
 #include "lib/ratio.h"
@@ -343,17 +344,17 @@ VideoPanel::range_changed ()
 
 
 void
-VideoPanel::film_changed (Film::Property property)
+VideoPanel::film_changed(FilmProperty property)
 {
        switch (property) {
-       case Film::Property::VIDEO_FRAME_RATE:
-       case Film::Property::CONTAINER:
-       case Film::Property::RESOLUTION:
+       case FilmProperty::VIDEO_FRAME_RATE:
+       case FilmProperty::CONTAINER:
+       case FilmProperty::RESOLUTION:
                setup_description ();
                setup_sensitivity ();
                break;
-       case Film::Property::REEL_TYPE:
-       case Film::Property::INTEROP:
+       case FilmProperty::REEL_TYPE:
+       case FilmProperty::INTEROP:
                setup_sensitivity ();
                break;
        default:
index 81e65d820e68b5e703320122422723b896af97c0..686d1b99b32300e951013f947b08fa20ec1ceee5 100644 (file)
@@ -27,7 +27,7 @@
 #include "content_sub_panel.h"
 #include "content_widget.h"
 #include "timecode.h"
-#include "lib/film.h"
+#include "lib/film_property.h"
 #include "lib/video_frame_type.h"
 
 
@@ -48,7 +48,7 @@ public:
        explicit VideoPanel (ContentPanel *);
 
        void create () override;
-       void film_changed (Film::Property) override;
+       void film_changed(FilmProperty) override;
        void film_content_changed (int) override;
        void content_selection_changed () override;
 
index 2774d0ef4c22276e5342e6e1c1ddcfaab46bb1a3..1bb289febeced38777bb38ef3025676ada3abdc3 100644 (file)
@@ -22,6 +22,7 @@
 #include "lib/content.h"
 #include "lib/content_factory.h"
 #include "lib/dcpomatic_time.h"
+#include "lib/film.h"
 #include "lib/player.h"
 #include "test.h"
 #include <boost/test/unit_test.hpp>