Fix merge.
authorCarl Hetherington <cth@carlh.net>
Wed, 9 Oct 2013 09:50:26 +0000 (10:50 +0100)
committerCarl Hetherington <cth@carlh.net>
Wed, 9 Oct 2013 09:50:26 +0000 (10:50 +0100)
1  2 
src/lib/config.cc
src/lib/writer.cc

diff --combined src/lib/config.cc
index 2429cbb3f65998a8aede504674fcc8c19718ffe0,ba899fe576a98b701d9043a432a9daa3acf320e1..79a7b01f1dd68f4aebf39cb07e5797533926abfa
@@@ -52,7 -52,7 +52,7 @@@ Config* Config::_instance = 0
  Config::Config ()
        : _num_local_encoding_threads (max (2U, boost::thread::hardware_concurrency()))
        , _server_port (6192)
-       , _tms_path (N_("."))
+       , _tms_path (".")
        , _sound_processor (SoundProcessor::from_id (N_("dolby_cp750")))
        , _default_still_length (10)
        , _default_container (Ratio::from_id ("185"))
@@@ -151,7 -151,7 +151,7 @@@ Config::read (
  void
  Config::read_old_metadata ()
  {
-       ifstream f (file(true).c_str ());
+       ifstream f (file(true).string().c_str ());
        string line;
  
        while (getline (f, line)) {
@@@ -221,8 -221,7 +221,8 @@@ Config::file (bool old) cons
        if (old) {
                p /= ".dvdomatic";
        } else {
 -              p /= "dcpomatic.xml";
 +              p /= "dcpomatic";
 +              p /= "config.xml";
        }
        return p;
  }
@@@ -232,7 -231,7 +232,7 @@@ Config::signer_chain_directory () cons
  {
        boost::filesystem::path p;
        p /= g_get_user_config_dir ();
 -      p /= "dvdomatic";
 +      p /= "dcpomatic";
        p /= "crypt";
        boost::filesystem::create_directories (p);
        return p;
diff --combined src/lib/writer.cc
index caa37c211b896c03918c148b8ee307f644555970,dc60e7947b9463341e933a5a5837267c0c8f18c9..5e8fb5b7a020bdf4be553d8bb65a005e80b5ac8f
  
  #include <fstream>
  #include <cerrno>
+ #include <libdcp/mono_picture_asset.h>
+ #include <libdcp/stereo_picture_asset.h>
  #include <libdcp/sound_asset.h>
- #include <libdcp/picture_frame.h>
  #include <libdcp/reel.h>
  #include <libdcp/dcp.h>
  #include <libdcp/cpl.h>
- #include <libdcp/mono_picture_asset.h>
- #include <libdcp/stereo_picture_asset.h>
  #include "writer.h"
  #include "compose.hpp"
  #include "film.h"
@@@ -75,9 -74,21 +74,9 @@@ Writer::Writer (shared_ptr<const Film> 
        */
  
        if (_film->three_d ()) {
 -              _picture_asset.reset (
 -                      new libdcp::StereoPictureAsset (
 -                              _film->internal_video_mxf_dir (),
 -                              _film->internal_video_mxf_filename ()
 -                              )
 -                      );
 -              
 +              _picture_asset.reset (new libdcp::StereoPictureAsset (_film->internal_video_mxf_dir (), _film->internal_video_mxf_filename ()));
        } else {
 -              _picture_asset.reset (
 -                      new libdcp::MonoPictureAsset (
 -                              _film->internal_video_mxf_dir (),
 -                              _film->internal_video_mxf_filename ()
 -                              )
 -                      );
 -
 +              _picture_asset.reset (new libdcp::MonoPictureAsset (_film->internal_video_mxf_dir (), _film->internal_video_mxf_filename ()));
        }
  
        _picture_asset->set_edit_rate (_film->video_frame_rate ());
        
        _picture_asset_writer = _picture_asset->start_write (_first_nonexistant_frame > 0);
        
 -      _sound_asset.reset (
 -              new libdcp::SoundAsset (
 -                      _film->dir (_film->dcp_name()),
 -                      _film->audio_mxf_filename ()
 -                      )
 -              );
 -
 +      _sound_asset.reset (new libdcp::SoundAsset (_film->dir (_film->dcp_name()), _film->audio_mxf_filename ()));
        _sound_asset->set_edit_rate (_film->video_frame_rate ());
        _sound_asset->set_channels (_film->audio_channels ());
        _sound_asset->set_sampling_rate (_film->audio_frame_rate ());
@@@ -396,7 -413,7 +395,7 @@@ Writer::finish (
  
        libdcp::XMLMetadata meta = Config::instance()->dcp_metadata ();
        meta.set_issue_date_now ();
 -      dcp.write_xml (_film->interop (), meta);
 +      dcp.write_xml (_film->interop (), meta, make_signer ());
  
        _film->log()->log (String::compose (N_("Wrote %1 FULL, %2 FAKE, %3 REPEAT; %4 pushed to disk"), _full_written, _fake_written, _repeat_written, _pushed_to_disk));
  }