diff options
| author | Carl Hetherington <cth@carlh.net> | 2018-07-07 23:16:45 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2018-07-07 23:16:45 +0100 |
| commit | ba5915461f1622715a69fa25579e5e27e64fb079 (patch) | |
| tree | 221ce87dfbac455c32459e07beb92b6003243e89 /tools | |
| parent | a4fb6290e31f7e197cc399c745d320442eb093d4 (diff) | |
SubtitleString -> shared_ptr<Subtitle>
Diffstat (limited to 'tools')
| -rw-r--r-- | tools/dcpinfo.cc | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/tools/dcpinfo.cc b/tools/dcpinfo.cc index 29ef77c9..92f12a3c 100644 --- a/tools/dcpinfo.cc +++ b/tools/dcpinfo.cc @@ -41,6 +41,7 @@ #include "reel_sound_asset.h" #include "reel_subtitle_asset.h" #include "subtitle_string.h" +#include "subtitle_image.h" #include "interop_subtitle_asset.h" #include "smpte_subtitle_asset.h" #include "mono_picture_asset.h" @@ -171,7 +172,7 @@ main_subtitle (shared_ptr<Reel> reel, bool list_subtitles) cout << " Subtitle ID: " << reel->main_subtitle()->id(); if (reel->main_subtitle()->asset_ref().resolved()) { - list<SubtitleString> subs = reel->main_subtitle()->asset()->subtitles (); + list<shared_ptr<Subtitle> > subs = reel->main_subtitle()->asset()->subtitles (); cout << "\n Subtitle: " << subs.size() << " subtitles"; shared_ptr<InteropSubtitleAsset> iop = dynamic_pointer_cast<InteropSubtitleAsset> (reel->main_subtitle()->asset()); if (iop) { @@ -182,8 +183,15 @@ main_subtitle (shared_ptr<Reel> reel, bool list_subtitles) cout << " in " << smpte->language().get() << "\n"; } if (list_subtitles) { - BOOST_FOREACH (SubtitleString const& k, subs) { - cout << k << "\n"; + BOOST_FOREACH (shared_ptr<Subtitle> k, subs) { + shared_ptr<SubtitleString> ks = dynamic_pointer_cast<SubtitleString> (k); + if (ks) { + cout << *ks << "\n"; + } + shared_ptr<SubtitleImage> is = dynamic_pointer_cast<SubtitleImage> (k); + if (is) { + cout << *is << "\n"; + } } } } else { |
