std::shared_ptr
[dcpomatic.git] / src / lib / audio_content.cc
index 014221f2e892afc95ef5f31d57aa3f4e44bea997..79a00b24934a577be5298ae716b2f76428c06070 100644 (file)
@@ -39,8 +39,8 @@ using std::fixed;
 using std::list;
 using std::pair;
 using std::setprecision;
-using boost::shared_ptr;
-using boost::dynamic_pointer_cast;
+using std::shared_ptr;
+using std::dynamic_pointer_cast;
 using boost::optional;
 using dcp::raw_convert;
 using namespace dcpomatic;
@@ -265,17 +265,18 @@ AudioContent::processing_description (shared_ptr<const Film> film) const
 }
 
 /** @return User-visible names of each of our audio channels */
-vector<string>
+vector<NamedChannel>
 AudioContent::channel_names () const
 {
-       vector<string> n;
+       vector<NamedChannel> n;
 
-       int t = 1;
+       int index = 0;
+       int stream = 1;
        BOOST_FOREACH (AudioStreamPtr i, streams ()) {
                for (int j = 0; j < i->channels(); ++j) {
-                       n.push_back (String::compose ("%1:%2", t, j + 1));
+                       n.push_back (NamedChannel(String::compose ("%1:%2", stream, j + 1), index++));
                }
-               ++t;
+               ++stream;
        }
 
        return n;