summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2015-06-04 16:48:08 +0100
committerCarl Hetherington <cth@carlh.net>2015-06-05 14:34:43 +0100
commit6c55e8d2c3b0129a19fc40dca344219021ad12ef (patch)
treecf9c3244ed55fb1fa8db89ca87923f3b7a6d35a1
parent2105caa32a12236d5b70a0cf8b9ac62fcf7f574e (diff)
Rename some stuff Content -> Asset.
-rw-r--r--examples/read_dcp.cc4
-rw-r--r--src/dcp.cc8
-rw-r--r--src/interop_subtitle_asset.cc (renamed from src/interop_subtitle_content.cc)20
-rw-r--r--src/interop_subtitle_asset.h (renamed from src/interop_subtitle_content.h)8
-rw-r--r--src/reel.cc2
-rw-r--r--src/reel_sound_asset.cc4
-rw-r--r--src/reel_subtitle_asset.cc6
-rw-r--r--src/reel_subtitle_asset.h12
-rw-r--r--src/smpte_subtitle_asset.cc (renamed from src/smpte_subtitle_content.cc)10
-rw-r--r--src/smpte_subtitle_asset.h (renamed from src/smpte_subtitle_content.h)6
-rw-r--r--src/subtitle_asset.cc (renamed from src/subtitle_content.cc)26
-rw-r--r--src/subtitle_asset.h (renamed from src/subtitle_content.h)12
-rw-r--r--src/wscript12
-rw-r--r--test/dcp_test.cc3
-rw-r--r--test/encryption_test.cc2
-rw-r--r--test/read_subtitle_test.cc8
-rw-r--r--test/rewrite_subs.cc4
-rw-r--r--test/smpte_subtitle_test.cc4
-rw-r--r--test/subs_in_out.cc6
-rw-r--r--test/write_subtitle_test.cc4
-rw-r--r--tools/dcpinfo.cc6
21 files changed, 83 insertions, 84 deletions
diff --git a/examples/read_dcp.cc b/examples/read_dcp.cc
index e5f28df1..068fc09b 100644
--- a/examples/read_dcp.cc
+++ b/examples/read_dcp.cc
@@ -31,7 +31,7 @@
#include "mono_picture_mxf.h"
#include "stereo_picture_mxf.h"
#include "sound_mxf.h"
-#include "subtitle_content.h"
+#include "subtitle_asset.h"
#include "xyz_image.h"
#include "colour_conversion.h"
#include "rgb_xyz.h"
@@ -66,7 +66,7 @@ main ()
std::cout << "3D picture\n";
} else if (boost::dynamic_pointer_cast<dcp::SoundMXF> (*i)) {
std::cout << "Sound\n";
- } else if (boost::dynamic_pointer_cast<dcp::SubtitleContent> (*i)) {
+ } else if (boost::dynamic_pointer_cast<dcp::SubtitleAsset> (*i)) {
std::cout << "Subtitle\n";
} else if (boost::dynamic_pointer_cast<dcp::CPL> (*i)) {
std::cout << "CPL\n";
diff --git a/src/dcp.cc b/src/dcp.cc
index 638ed707..e1b632c6 100644
--- a/src/dcp.cc
+++ b/src/dcp.cc
@@ -25,8 +25,8 @@
#include "dcp.h"
#include "sound_mxf.h"
#include "picture_mxf.h"
-#include "interop_subtitle_content.h"
-#include "smpte_subtitle_content.h"
+#include "interop_subtitle_asset.h"
+#include "smpte_subtitle_asset.h"
#include "mono_picture_mxf.h"
#include "stereo_picture_mxf.h"
#include "util.h"
@@ -137,7 +137,7 @@ DCP::read (bool keep_going, ReadErrors* errors)
if (root == "CompositionPlaylist") {
_assets.push_back (shared_ptr<CPL> (new CPL (path)));
} else if (root == "DCSubtitle") {
- _assets.push_back (shared_ptr<InteropSubtitleContent> (new InteropSubtitleContent (path)));
+ _assets.push_back (shared_ptr<InteropSubtitleAsset> (new InteropSubtitleAsset (path)));
}
} else if (boost::algorithm::ends_with (path.string(), ".mxf")) {
ASDCP::EssenceType_t type;
@@ -159,7 +159,7 @@ DCP::read (bool keep_going, ReadErrors* errors)
_assets.push_back (shared_ptr<StereoPictureMXF> (new StereoPictureMXF (path)));
break;
case ASDCP::ESS_TIMED_TEXT:
- _assets.push_back (shared_ptr<SMPTESubtitleContent> (new SMPTESubtitleContent (path)));
+ _assets.push_back (shared_ptr<SMPTESubtitleAsset> (new SMPTESubtitleAsset (path)));
break;
default:
throw DCPReadError ("Unknown MXF essence type");
diff --git a/src/interop_subtitle_content.cc b/src/interop_subtitle_asset.cc
index 29da0b21..a6bdfcaf 100644
--- a/src/interop_subtitle_content.cc
+++ b/src/interop_subtitle_asset.cc
@@ -17,7 +17,7 @@
*/
-#include "interop_subtitle_content.h"
+#include "interop_subtitle_asset.h"
#include "interop_load_font_node.h"
#include "xml.h"
#include "raw_convert.h"
@@ -34,8 +34,8 @@ using boost::optional;
using boost::dynamic_pointer_cast;
using namespace dcp;
-InteropSubtitleContent::InteropSubtitleContent (boost::filesystem::path file)
- : SubtitleContent (file)
+InteropSubtitleAsset::InteropSubtitleAsset (boost::filesystem::path file)
+ : SubtitleAsset (file)
{
shared_ptr<cxml::Document> xml (new cxml::Document ("DCSubtitle"));
xml->read_file (file);
@@ -53,7 +53,7 @@ InteropSubtitleContent::InteropSubtitleContent (boost::filesystem::path file)
parse_common (xml, font_nodes);
}
-InteropSubtitleContent::InteropSubtitleContent (string movie_title, string language)
+InteropSubtitleAsset::InteropSubtitleAsset (string movie_title, string language)
: _movie_title (movie_title)
{
_language = language;
@@ -69,7 +69,7 @@ struct SubtitleSorter {
};
Glib::ustring
-InteropSubtitleContent::xml_as_string () const
+InteropSubtitleAsset::xml_as_string () const
{
xmlpp::Document doc;
xmlpp::Element* root = doc.create_root_node ("DCSubtitle");
@@ -187,19 +187,19 @@ InteropSubtitleContent::xml_as_string () const
}
void
-InteropSubtitleContent::add_font (string id, string uri)
+InteropSubtitleAsset::add_font (string id, string uri)
{
_load_font_nodes.push_back (shared_ptr<InteropLoadFontNode> (new InteropLoadFontNode (id, uri)));
}
bool
-InteropSubtitleContent::equals (shared_ptr<const Asset> other_asset, EqualityOptions options, NoteHandler note) const
+InteropSubtitleAsset::equals (shared_ptr<const Asset> other_asset, EqualityOptions options, NoteHandler note) const
{
- if (!SubtitleContent::equals (other_asset, options, note)) {
+ if (!SubtitleAsset::equals (other_asset, options, note)) {
return false;
}
- shared_ptr<const InteropSubtitleContent> other = dynamic_pointer_cast<const InteropSubtitleContent> (other_asset);
+ shared_ptr<const InteropSubtitleAsset> other = dynamic_pointer_cast<const InteropSubtitleAsset> (other_asset);
if (!other) {
return false;
}
@@ -231,7 +231,7 @@ InteropSubtitleContent::equals (shared_ptr<const Asset> other_asset, EqualityOpt
}
list<shared_ptr<LoadFontNode> >
-InteropSubtitleContent::load_font_nodes () const
+InteropSubtitleAsset::load_font_nodes () const
{
list<shared_ptr<LoadFontNode> > lf;
copy (_load_font_nodes.begin(), _load_font_nodes.end(), back_inserter (lf));
diff --git a/src/interop_subtitle_content.h b/src/interop_subtitle_asset.h
index cb7c52d5..586bb67c 100644
--- a/src/interop_subtitle_content.h
+++ b/src/interop_subtitle_asset.h
@@ -17,18 +17,18 @@
*/
-#include "subtitle_content.h"
+#include "subtitle_asset.h"
#include <boost/filesystem.hpp>
namespace dcp {
class InteropLoadFontNode;
-class InteropSubtitleContent : public SubtitleContent
+class InteropSubtitleAsset : public SubtitleAsset
{
public:
- InteropSubtitleContent (std::string movie_title, std::string language);
- InteropSubtitleContent (boost::filesystem::path file);
+ InteropSubtitleAsset (std::string movie_title, std::string language);
+ InteropSubtitleAsset (boost::filesystem::path file);
bool equals (
boost::shared_ptr<const Asset>,
diff --git a/src/reel.cc b/src/reel.cc
index eb682aea..3a046297 100644
--- a/src/reel.cc
+++ b/src/reel.cc
@@ -23,7 +23,7 @@
#include "mono_picture_mxf.h"
#include "stereo_picture_mxf.h"
#include "sound_mxf.h"
-#include "subtitle_content.h"
+#include "subtitle_asset.h"
#include "reel_mono_picture_asset.h"
#include "reel_stereo_picture_asset.h"
#include "reel_sound_asset.h"
diff --git a/src/reel_sound_asset.cc b/src/reel_sound_asset.cc
index a5e32b02..9d3e00d7 100644
--- a/src/reel_sound_asset.cc
+++ b/src/reel_sound_asset.cc
@@ -29,8 +29,8 @@ using std::string;
using boost::shared_ptr;
using namespace dcp;
-ReelSoundAsset::ReelSoundAsset (shared_ptr<SoundMXF> content, int64_t entry_point)
- : ReelMXFAsset (content, content->edit_rate(), content->intrinsic_duration(), entry_point)
+ReelSoundAsset::ReelSoundAsset (shared_ptr<SoundMXF> asset, int64_t entry_point)
+ : ReelMXFAsset (asset, asset->edit_rate(), asset->intrinsic_duration(), entry_point)
{
}
diff --git a/src/reel_subtitle_asset.cc b/src/reel_subtitle_asset.cc
index 139e3a39..ed0376ed 100644
--- a/src/reel_subtitle_asset.cc
+++ b/src/reel_subtitle_asset.cc
@@ -21,15 +21,15 @@
* @brief ReelSubtitleAsset class.
*/
-#include "subtitle_content.h"
+#include "subtitle_asset.h"
#include "reel_subtitle_asset.h"
using std::string;
using boost::shared_ptr;
using namespace dcp;
-ReelSubtitleAsset::ReelSubtitleAsset (boost::shared_ptr<SubtitleContent> content, Fraction edit_rate, int64_t intrinsic_duration, int64_t entry_point)
- : ReelAsset (content, edit_rate, intrinsic_duration, entry_point)
+ReelSubtitleAsset::ReelSubtitleAsset (boost::shared_ptr<SubtitleAsset> asset, Fraction edit_rate, int64_t intrinsic_duration, int64_t entry_point)
+ : ReelAsset (asset, edit_rate, intrinsic_duration, entry_point)
{
}
diff --git a/src/reel_subtitle_asset.h b/src/reel_subtitle_asset.h
index bc00b4c3..f296fdc6 100644
--- a/src/reel_subtitle_asset.h
+++ b/src/reel_subtitle_asset.h
@@ -1,5 +1,5 @@
/*
- Copyright (C) 2012-2014 Carl Hetherington <cth@carlh.net>
+ Copyright (C) 2012-2015 Carl Hetherington <cth@carlh.net>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -25,11 +25,11 @@
#define LIBDCP_REEL_SUBTITLE_ASSET_H
#include "reel_asset.h"
-#include "subtitle_content.h"
+#include "subtitle_asset.h"
namespace dcp {
-class SubtitleContent;
+class SubtitleAsset;
/** @class ReelSubtitleAsset
* @brief Part of a Reel's description which refers to a subtitle XML file.
@@ -37,11 +37,11 @@ class SubtitleContent;
class ReelSubtitleAsset : public ReelAsset
{
public:
- ReelSubtitleAsset (boost::shared_ptr<SubtitleContent> content, Fraction edit_rate, int64_t instrinsic_duration, int64_t entry_point);
+ ReelSubtitleAsset (boost::shared_ptr<SubtitleAsset> asset, Fraction edit_rate, int64_t instrinsic_duration, int64_t entry_point);
ReelSubtitleAsset (boost::shared_ptr<const cxml::Node>);
- boost::shared_ptr<SubtitleContent> subtitle_content () const {
- return boost::dynamic_pointer_cast<SubtitleContent> (_asset.object ());
+ boost::shared_ptr<SubtitleAsset> subtitle_asset () const {
+ return boost::dynamic_pointer_cast<SubtitleAsset> (_asset.object ());
}
private:
diff --git a/src/smpte_subtitle_content.cc b/src/smpte_subtitle_asset.cc
index e95a64fc..e5a083b1 100644
--- a/src/smpte_subtitle_content.cc
+++ b/src/smpte_subtitle_asset.cc
@@ -17,7 +17,7 @@
*/
-#include "smpte_subtitle_content.h"
+#include "smpte_subtitle_asset.h"
#include "smpte_load_font_node.h"
#include "font_node.h"
#include "exceptions.h"
@@ -33,8 +33,8 @@ using std::cout;
using boost::shared_ptr;
using namespace dcp;
-SMPTESubtitleContent::SMPTESubtitleContent (boost::filesystem::path file, bool mxf)
- : SubtitleContent (file)
+SMPTESubtitleAsset::SMPTESubtitleAsset (boost::filesystem::path file, bool mxf)
+ : SubtitleAsset (file)
{
shared_ptr<cxml::Document> xml (new cxml::Document ("SubtitleReel"));
@@ -78,7 +78,7 @@ SMPTESubtitleContent::SMPTESubtitleContent (boost::filesystem::path file, bool m
}
list<shared_ptr<LoadFontNode> >
-SMPTESubtitleContent::load_font_nodes () const
+SMPTESubtitleAsset::load_font_nodes () const
{
list<shared_ptr<LoadFontNode> > lf;
copy (_load_font_nodes.begin(), _load_font_nodes.end(), back_inserter (lf));
@@ -86,7 +86,7 @@ SMPTESubtitleContent::load_font_nodes () const
}
bool
-SMPTESubtitleContent::valid_mxf (boost::filesystem::path file)
+SMPTESubtitleAsset::valid_mxf (boost::filesystem::path file)
{
ASDCP::TimedText::MXFReader reader;
Kumu::Result_t r = reader.OpenRead (file.string().c_str ());
diff --git a/src/smpte_subtitle_content.h b/src/smpte_subtitle_asset.h
index 8526e0ec..639c8eb7 100644
--- a/src/smpte_subtitle_content.h
+++ b/src/smpte_subtitle_asset.h
@@ -17,20 +17,20 @@
*/
-#include "subtitle_content.h"
+#include "subtitle_asset.h"
#include <boost/filesystem.hpp>
namespace dcp {
class SMPTELoadFontNode;
-class SMPTESubtitleContent : public SubtitleContent
+class SMPTESubtitleAsset : public SubtitleAsset
{
public:
/** @param file File name
* @param mxf true if `file' is a MXF, or false if it is an XML file.
*/
- SMPTESubtitleContent (boost::filesystem::path file, bool mxf = true);
+ SMPTESubtitleAsset (boost::filesystem::path file, bool mxf = true);
std::list<boost::shared_ptr<LoadFontNode> > load_font_nodes () const;
diff --git a/src/subtitle_content.cc b/src/subtitle_asset.cc
index d2be6fe0..f1ecc939 100644
--- a/src/subtitle_content.cc
+++ b/src/subtitle_asset.cc
@@ -18,7 +18,7 @@
*/
#include "raw_convert.h"
-#include "subtitle_content.h"
+#include "subtitle_asset.h"
#include "util.h"
#include "xml.h"
#include "font_node.h"
@@ -42,13 +42,13 @@ using boost::optional;
using boost::dynamic_pointer_cast;
using namespace dcp;
-SubtitleContent::SubtitleContent ()
+SubtitleAsset::SubtitleAsset ()
: _reel_number ("1")
{
}
-SubtitleContent::SubtitleContent (boost::filesystem::path file)
+SubtitleAsset::SubtitleAsset (boost::filesystem::path file)
: Asset (file)
, _reel_number ("1")
{
@@ -56,7 +56,7 @@ SubtitleContent::SubtitleContent (boost::filesystem::path file)
}
void
-SubtitleContent::parse_common (shared_ptr<cxml::Document> xml, list<shared_ptr<dcp::FontNode> > font_nodes)
+SubtitleAsset::parse_common (shared_ptr<cxml::Document> xml, list<shared_ptr<dcp::FontNode> > font_nodes)
{
_reel_number = xml->string_child ("ReelNumber");
_language = xml->string_child ("Language");
@@ -70,7 +70,7 @@ SubtitleContent::parse_common (shared_ptr<cxml::Document> xml, list<shared_ptr<d
}
void
-SubtitleContent::examine_font_nodes (
+SubtitleAsset::examine_font_nodes (
shared_ptr<const cxml::Node> xml,
list<shared_ptr<dcp::FontNode> > const & font_nodes,
ParseState& parse_state
@@ -96,7 +96,7 @@ SubtitleContent::examine_font_nodes (
}
void
-SubtitleContent::examine_text_nodes (
+SubtitleAsset::examine_text_nodes (
shared_ptr<const cxml::Node> xml,
list<shared_ptr<dcp::TextNode> > const & text_nodes,
ParseState& parse_state
@@ -111,7 +111,7 @@ SubtitleContent::examine_text_nodes (
}
void
-SubtitleContent::maybe_add_subtitle (string text, ParseState const & parse_state)
+SubtitleAsset::maybe_add_subtitle (string text, ParseState const & parse_state)
{
if (empty_or_white_space (text)) {
return;
@@ -151,7 +151,7 @@ SubtitleContent::maybe_add_subtitle (string text, ParseState const & parse_state
}
list<SubtitleString>
-SubtitleContent::subtitles_during (Time from, Time to) const
+SubtitleAsset::subtitles_during (Time from, Time to) const
{
list<SubtitleString> s;
for (list<SubtitleString>::const_iterator i = _subtitles.begin(); i != _subtitles.end(); ++i) {
@@ -164,13 +164,13 @@ SubtitleContent::subtitles_during (Time from, Time to) const
}
void
-SubtitleContent::add (SubtitleString s)
+SubtitleAsset::add (SubtitleString s)
{
_subtitles.push_back (s);
}
void
-SubtitleContent::write_xml (boost::filesystem::path p) const
+SubtitleAsset::write_xml (boost::filesystem::path p) const
{
FILE* f = fopen_boost (p, "w");
if (!f) {
@@ -185,7 +185,7 @@ SubtitleContent::write_xml (boost::filesystem::path p) const
}
Time
-SubtitleContent::latest_subtitle_out () const
+SubtitleAsset::latest_subtitle_out () const
{
Time t;
for (list<SubtitleString>::const_iterator i = _subtitles.begin(); i != _subtitles.end(); ++i) {
@@ -198,13 +198,13 @@ SubtitleContent::latest_subtitle_out () const
}
bool
-SubtitleContent::equals (shared_ptr<const Asset> other_asset, EqualityOptions options, NoteHandler note) const
+SubtitleAsset::equals (shared_ptr<const Asset> other_asset, EqualityOptions options, NoteHandler note) const
{
if (!Asset::equals (other_asset, options, note)) {
return false;
}
- shared_ptr<const SubtitleContent> other = dynamic_pointer_cast<const SubtitleContent> (other_asset);
+ shared_ptr<const SubtitleAsset> other = dynamic_pointer_cast<const SubtitleAsset> (other_asset);
if (!other) {
return false;
}
diff --git a/src/subtitle_content.h b/src/subtitle_asset.h
index d80d631c..deb72ece 100644
--- a/src/subtitle_content.h
+++ b/src/subtitle_asset.h
@@ -17,8 +17,8 @@
*/
-#ifndef LIBDCP_SUBTITLE_CONTENT_H
-#define LIBDCP_SUBTITLE_CONTENT_H
+#ifndef LIBDCP_SUBTITLE_ASSET_H
+#define LIBDCP_SUBTITLE_ASSET_H
#include "asset.h"
#include "dcp_time.h"
@@ -34,14 +34,14 @@ class TextNode;
class SubtitleNode;
class LoadFontNode;
-/** @class SubtitleContent
+/** @class SubtitleAsset
* @brief A parent for classes representing a file containing subtitles.
*/
-class SubtitleContent : public Asset
+class SubtitleAsset : public Asset
{
public:
- SubtitleContent ();
- SubtitleContent (boost::filesystem::path file);
+ SubtitleAsset ();
+ SubtitleAsset (boost::filesystem::path file);
bool equals (
boost::shared_ptr<const Asset>,
diff --git a/src/wscript b/src/wscript
index 7328178b..54f3a03b 100644
--- a/src/wscript
+++ b/src/wscript
@@ -19,7 +19,7 @@ def build(bld):
font_node.cc
gamma_transfer_function.cc
interop_load_font_node.cc
- interop_subtitle_content.cc
+ interop_subtitle_asset.cc
key.cc
local_time.cc
metadata.cc
@@ -43,7 +43,7 @@ def build(bld):
rgb_xyz.cc
signer.cc
smpte_load_font_node.cc
- smpte_subtitle_content.cc
+ smpte_subtitle_asset.cc
sound_mxf.cc
sound_mxf_writer.cc
sound_frame.cc
@@ -51,7 +51,7 @@ def build(bld):
stereo_picture_mxf_writer.cc
stereo_picture_frame.cc
subtitle_node.cc
- subtitle_content.cc
+ subtitle_asset.cc
subtitle_string.cc
text_node.cc
transfer_function.cc
@@ -78,7 +78,7 @@ def build(bld):
font.h
gamma_transfer_function.h
interop_load_font_node.h
- interop_subtitle_content.h
+ interop_subtitle_asset.h
key.h
load_font_node.h
local_time.h
@@ -104,14 +104,14 @@ def build(bld):
ref.h
signer.h
smpte_load_font_node.h
- smpte_subtitle_content.h
+ smpte_subtitle_asset.h
sound_frame.h
sound_mxf.h
sound_mxf_writer.h
stereo_picture_mxf.h
stereo_picture_frame.h
subtitle_node.h
- subtitle_content.h
+ subtitle_asset.h
subtitle_string.h
transfer_function.h
types.h
diff --git a/test/dcp_test.cc b/test/dcp_test.cc
index 5bedf5f6..6da30ffe 100644
--- a/test/dcp_test.cc
+++ b/test/dcp_test.cc
@@ -1,5 +1,5 @@
/*
- Copyright (C) 2013-2014 Carl Hetherington <cth@carlh.net>
+ Copyright (C) 2013-2015 Carl Hetherington <cth@carlh.net>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -25,7 +25,6 @@
#include "picture_mxf_writer.h"
#include "sound_mxf_writer.h"
#include "sound_mxf.h"
-#include "subtitle_content.h"
#include "reel.h"
#include "test.h"
#include "file.h"
diff --git a/test/encryption_test.cc b/test/encryption_test.cc
index 173ccf59..6dc37b8d 100644
--- a/test/encryption_test.cc
+++ b/test/encryption_test.cc
@@ -30,7 +30,7 @@
#include "reel.h"
#include "test.h"
#include "file.h"
-#include "subtitle_content.h"
+#include "subtitle_asset.h"
#include "reel_mono_picture_asset.h"
#include "reel_sound_asset.h"
#include "encrypted_kdm.h"
diff --git a/test/read_subtitle_test.cc b/test/read_subtitle_test.cc
index 42bd2ee4..c49ddfdf 100644
--- a/test/read_subtitle_test.cc
+++ b/test/read_subtitle_test.cc
@@ -1,5 +1,5 @@
/*
- Copyright (C) 2012-2014 Carl Hetherington <cth@carlh.net>
+ Copyright (C) 2012-2015 Carl Hetherington <cth@carlh.net>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -17,7 +17,7 @@
*/
-#include "interop_subtitle_content.h"
+#include "interop_subtitle_asset.h"
#include "subtitle_string.h"
#include <boost/test/unit_test.hpp>
@@ -28,7 +28,7 @@ using boost::shared_ptr;
/* Load some subtitle content from XML and check that it is read correctly */
BOOST_AUTO_TEST_CASE (read_subtitle_test1)
{
- dcp::InteropSubtitleContent subs ("test/data/subs1.xml");
+ dcp::InteropSubtitleAsset subs ("test/data/subs1.xml");
BOOST_CHECK_EQUAL (subs.language(), "French");
@@ -138,7 +138,7 @@ BOOST_AUTO_TEST_CASE (read_subtitle_test1)
/** And similarly for another one */
BOOST_AUTO_TEST_CASE (read_subtitle_test2)
{
- dcp::InteropSubtitleContent subs ("test/data/subs2.xml");
+ dcp::InteropSubtitleAsset subs ("test/data/subs2.xml");
list<dcp::SubtitleString> s = subs.subtitles_during (dcp::Time (0, 0, 42, 100, 250), dcp::Time (0, 0, 42, 101, 250));
BOOST_REQUIRE_EQUAL (s.size(), 2);
diff --git a/test/rewrite_subs.cc b/test/rewrite_subs.cc
index 1a3cfbff..e62b9169 100644
--- a/test/rewrite_subs.cc
+++ b/test/rewrite_subs.cc
@@ -21,7 +21,7 @@
#include "dcp.h"
#include "cpl.h"
#include "reel.h"
-#include "subtitle_content.h"
+#include "subtitle_asset.h"
#include "reel_subtitle_asset.h"
#include "exceptions.h"
@@ -51,7 +51,7 @@ main (int argc, char* argv[])
for (list<shared_ptr<Reel> >::iterator j = reels.begin(); j != reels.end(); ++j) {
if ((*j)->main_subtitle()) {
- (*j)->main_subtitle()->subtitle_content()->write_xml ((*j)->main_subtitle()->subtitle_content()->file ());
+ (*j)->main_subtitle()->subtitle_asset()->write_xml ((*j)->main_subtitle()->subtitle_asset()->file ());
}
}
}
diff --git a/test/smpte_subtitle_test.cc b/test/smpte_subtitle_test.cc
index 74bfa7a2..2b68de3d 100644
--- a/test/smpte_subtitle_test.cc
+++ b/test/smpte_subtitle_test.cc
@@ -17,14 +17,14 @@
*/
-#include "smpte_subtitle_content.h"
+#include "smpte_subtitle_asset.h"
#include "test.h"
#include <boost/test/unit_test.hpp>
/** Load a SMPTE XML subtitle file */
BOOST_AUTO_TEST_CASE (smpte_subtitle_test)
{
- dcp::SMPTESubtitleContent sc (private_test / "8dfafe11-2bd1-4206-818b-afc109cfe7f6_reel1.xml", false);
+ dcp::SMPTESubtitleAsset sc (private_test / "8dfafe11-2bd1-4206-818b-afc109cfe7f6_reel1.xml", false);
BOOST_REQUIRE_EQUAL (sc.id(), "8dfafe11-2bd1-4206-818b-afc109cfe7f6");
BOOST_REQUIRE_EQUAL (sc.subtitles().size(), 159);
diff --git a/test/subs_in_out.cc b/test/subs_in_out.cc
index e5d6c19c..2a662262 100644
--- a/test/subs_in_out.cc
+++ b/test/subs_in_out.cc
@@ -1,5 +1,5 @@
/*
- Copyright (C) 2012-2014 Carl Hetherington <cth@carlh.net>
+ Copyright (C) 2012-2015 Carl Hetherington <cth@carlh.net>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -17,7 +17,7 @@
*/
-#include "interop_subtitle_content.h"
+#include "interop_subtitle_asset.h"
#include <iostream>
using namespace std;
@@ -29,7 +29,7 @@ int main (int argc, char* argv[])
exit (EXIT_FAILURE);
}
- dcp::InteropSubtitleContent s (argv[1]);
+ dcp::InteropSubtitleAsset s (argv[1]);
cout << s.xml_as_string ();
return 0;
}
diff --git a/test/write_subtitle_test.cc b/test/write_subtitle_test.cc
index 1a6f96bd..b02a6e59 100644
--- a/test/write_subtitle_test.cc
+++ b/test/write_subtitle_test.cc
@@ -17,7 +17,7 @@
*/
-#include "interop_subtitle_content.h"
+#include "interop_subtitle_asset.h"
#include "subtitle_string.h"
#include "test.h"
#include <boost/test/unit_test.hpp>
@@ -29,7 +29,7 @@ using boost::shared_ptr;
/* Write some subtitle content as Interop XML and check that it is right */
BOOST_AUTO_TEST_CASE (write_subtitle_test)
{
- dcp::InteropSubtitleContent c ("Test", "EN");
+ dcp::InteropSubtitleAsset c ("Test", "EN");
c.add (
dcp::SubtitleString (
diff --git a/tools/dcpinfo.cc b/tools/dcpinfo.cc
index c278fc2f..119a2106 100644
--- a/tools/dcpinfo.cc
+++ b/tools/dcpinfo.cc
@@ -22,7 +22,7 @@
#include "reel.h"
#include "sound_mxf.h"
#include "picture_mxf.h"
-#include "subtitle_content.h"
+#include "subtitle_asset.h"
#include "reel_picture_asset.h"
#include "reel_sound_asset.h"
#include "reel_subtitle_asset.h"
@@ -80,8 +80,8 @@ main_subtitle (shared_ptr<Reel> reel, bool list_subtitles)
return;
}
- list<SubtitleString> subs = reel->main_subtitle()->subtitle_content()->subtitles ();
- cout << " Subtitle: " << subs.size() << " subtitles in " << reel->main_subtitle()->subtitle_content()->language() << "\n";
+ list<SubtitleString> subs = reel->main_subtitle()->subtitle_asset()->subtitles ();
+ cout << " Subtitle: " << subs.size() << " subtitles in " << reel->main_subtitle()->subtitle_asset()->language() << "\n";
if (list_subtitles) {
BOOST_FOREACH (SubtitleString const& k, subs) {
cout << k << "\n";