diff options
| author | Carl Hetherington <cth@carlh.net> | 2014-05-30 10:53:53 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2014-05-30 10:53:53 +0100 |
| commit | 38a5ff713757b9dc0cb67cb09613182c46dc9657 (patch) | |
| tree | ef337ee8bcd315b85f3a50ce37f623f3b1c51d76 /src/stl_binary_reader.cc | |
| parent | 97495d8cce58f0e5d9a43977698c60b8b66a83e3 (diff) | |
Split up into RawSubtitle and Subtitle, with collect(). Hopefully cleaner.
Diffstat (limited to 'src/stl_binary_reader.cc')
| -rw-r--r-- | src/stl_binary_reader.cc | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/src/stl_binary_reader.cc b/src/stl_binary_reader.cc index b0701b5..6c02526 100644 --- a/src/stl_binary_reader.cc +++ b/src/stl_binary_reader.cc @@ -104,7 +104,7 @@ STLBinaryReader::STLBinaryReader (istream& in) split (lines, whole, is_any_of ("\x8a")); for (size_t i = 0; i < lines.size(); ++i) { - Subtitle sub; + RawSubtitle sub; sub.from.set_frame (get_timecode (5)); sub.to.set_frame (get_timecode (9)); sub.vertical_position.line = get_int (13, 1) + i; @@ -117,10 +117,7 @@ STLBinaryReader::STLBinaryReader (istream& in) lines[i] = lines[i].substr (0, unused); } - Block block; - block.text = utf_to_utf<char> (iso6937_to_utf16 (lines[i].c_str())); - sub.blocks.push_back (block); - + sub.text = utf_to_utf<char> (iso6937_to_utf16 (lines[i].c_str())); _subs.push_back (sub); } } |
