Merge.
authorCarl Hetherington <cth@carlh.net>
Sat, 14 Feb 2015 21:37:28 +0000 (21:37 +0000)
committerCarl Hetherington <cth@carlh.net>
Sat, 14 Feb 2015 21:37:28 +0000 (21:37 +0000)
ChangeLog
TO_PORT
src/lib/dcp_content.cc
src/lib/image_content.cc
src/lib/types.h
src/lib/video_content.cc
src/lib/video_content.h
src/wx/about_dialog.cc

index d87f1596174177b09292f71e71542cf03038094f..0e5d600fad95a11987e13eca48ce087b2ffb83b2 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2015-02-10  c.hetherington  <cth@carlh.net>
+
+       * Default to no colour conversion for
+       JPEG2000 and DCP content (#445).
+
 2015-02-06  Carl Hetherington  <cth@carlh.net>
 
        * Version 2.0.40 released.
diff --git a/TO_PORT b/TO_PORT
index 441eb1a6717b5d991b6e02fd7f3747985d13136d..29155e0218a60d141b1746c5606c5b9359c74520 100644 (file)
--- a/TO_PORT
+++ b/TO_PORT
@@ -1,3 +1,4 @@
 e6c9d208c52fb6f8bc29469e7d263bd03b22fe48
 31894d178c8f6a3378b1c25c7ea1971f78759156
 bb2bdf010dd2ea813f9ac7af5023ce39cf14f572
+c065accc4b4c6ed268e7fccea77a958473be7785
index 3f3cb1b94d71600b052d5d427a29bbfaae935ed3..51c7f8549ba504fe75a090509893317da526ca9d 100644 (file)
@@ -47,6 +47,8 @@ DCPContent::DCPContent (shared_ptr<const Film> f, boost::filesystem::path p)
        , _kdm_valid (false)
 {
        read_directory (p);
+       /* Default to no colour conversion for DCPs */
+       unset_colour_conversion (false);
 }
 
 DCPContent::DCPContent (shared_ptr<const Film> f, cxml::ConstNodePtr node, int version)
index 1dbd7871b9f9a22d51f2a296094209499922bb87..4073cd52c7facf71117f43b3d33a0c044359d01e 100644 (file)
@@ -37,12 +37,19 @@ ImageContent::ImageContent (shared_ptr<const Film> f, boost::filesystem::path p)
        : Content (f)
        , VideoContent (f)
 {
+       bool have_j2k = false;
        if (boost::filesystem::is_regular_file (p)) {
                _paths.push_back (p);
+               if (valid_j2k_file (p)) {
+                       have_j2k = true;
+               }
        } else {
                for (boost::filesystem::directory_iterator i(p); i != boost::filesystem::directory_iterator(); ++i) {
                        if (boost::filesystem::is_regular_file (i->path()) && valid_image_file (i->path())) {
                                _paths.push_back (i->path ());
+                               if (valid_j2k_file (i->path ())) {
+                                       have_j2k = true;
+                               }
                        }
                }
 
@@ -52,6 +59,11 @@ ImageContent::ImageContent (shared_ptr<const Film> f, boost::filesystem::path p)
                                
                sort (_paths.begin(), _paths.end());
        }
+
+       if (have_j2k) {
+               /* We default to no colour conversion if we have JPEG2000 files */
+               unset_colour_conversion ();
+       }
 }
 
 
index f554c4dd9ad1f72dc0094fb625eed35c116e0aad..12a7897dc7c3ed374f15e5a878ef85db347ec709 100644 (file)
@@ -46,7 +46,7 @@ namespace xmlpp {
  *  with servers.  Intended to be bumped when incompatibilities
  *  are introduced.
  */
-#define SERVER_LINK_VERSION 2
+#define SERVER_LINK_VERSION 3
 
 typedef std::vector<boost::shared_ptr<Content> > ContentList;
 typedef std::vector<boost::shared_ptr<VideoContent> > VideoContentList;
index 823517bfc0af47103ac146f30cae854b3ebabd79..64c51be99f7bd65de0f2560700c0cf9ba58e91bf 100644 (file)
@@ -393,14 +393,16 @@ VideoContent::video_size_after_3d_split () const
 }
 
 void
-VideoContent::unset_colour_conversion ()
+VideoContent::unset_colour_conversion (bool signal)
 {
        {
                boost::mutex::scoped_lock lm (_mutex);
                _colour_conversion = boost::optional<ColourConversion> ();
        }
 
-       signal_changed (VideoContentProperty::COLOUR_CONVERSION);
+       if (signal) {
+               signal_changed (VideoContentProperty::COLOUR_CONVERSION);
+       }
 }
 
 void
index 3209261902d2bb497e9ad6155c83e2e853dd06aa..792929419c42f36e091efe40ef583df3eb20b7d3 100644 (file)
@@ -86,7 +86,7 @@ public:
        void set_bottom_crop (int);
 
        void set_scale (VideoContentScale);
-       void unset_colour_conversion ();
+       void unset_colour_conversion (bool signal = true);
        void set_colour_conversion (ColourConversion);
        void set_default_colour_conversion (bool signal = true);
 
index 7b4d02f38253da55fd7b34e5f25c407320b67587..d110ac3fd0dbf741c822914a79ae8e7970025277 100644 (file)
@@ -190,6 +190,7 @@ AboutDialog::AboutDialog (wxWindow* parent)
        tested_by.Add (wxT ("Adam Colt"));
        tested_by.Add (wxT ("John Convertino"));
        tested_by.Add (wxT ("Andreas Eli"));
+       tested_by.Add (wxT ("Jose Angel Velasco Fernandez"));
        tested_by.Add (wxT ("Maurizio GiampĂ "));
        tested_by.Add (wxT ("Luke Granger-Brown"));
        tested_by.Add (wxT ("Sumit Guha"));