db8af2f changed rebase() to round down when rebasing times, but
[libdcp.git] / test / write_subtitle_test.cc
1 /*
2     Copyright (C) 2015-2016 Carl Hetherington <cth@carlh.net>
3
4     This file is part of libdcp.
5
6     libdcp is free software; you can redistribute it and/or modify
7     it under the terms of the GNU General Public License as published by
8     the Free Software Foundation; either version 2 of the License, or
9     (at your option) any later version.
10
11     libdcp is distributed in the hope that it will be useful,
12     but WITHOUT ANY WARRANTY; without even the implied warranty of
13     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14     GNU General Public License for more details.
15
16     You should have received a copy of the GNU General Public License
17     along with libdcp.  If not, see <http://www.gnu.org/licenses/>.
18 */
19
20 #include "interop_subtitle_asset.h"
21 #include "smpte_subtitle_asset.h"
22 #include "subtitle_string.h"
23 #include "subtitle_asset_internal.h"
24 #include "test.h"
25 #include <boost/test/unit_test.hpp>
26
27 using std::list;
28 using std::string;
29 using boost::shared_ptr;
30
31 /** Test dcp::order::Font::take_intersection */
32 BOOST_AUTO_TEST_CASE (take_intersection_test)
33 {
34         dcp::order::Font A;
35         A._values["foo"] = "bar";
36         A._values["fred"] = "jim";
37
38         dcp::order::Font B;
39         B._values["foo"] = "bar";
40         B._values["sheila"] = "baz";
41
42         A.take_intersection (B);
43         BOOST_REQUIRE_EQUAL (A._values.size(), 1);
44         BOOST_CHECK_EQUAL (A._values["foo"], "bar");
45
46         A._values.clear ();
47         B._values.clear ();
48
49         A._values["foo"] = "bar";
50         A._values["fred"] = "jim";
51
52         B._values["foo"] = "hello";
53         B._values["sheila"] = "baz";
54
55         A.take_intersection (B);
56         BOOST_CHECK_EQUAL (A._values.size(), 0);
57 }
58
59 /** Test dcp::order::Font::take_difference */
60 BOOST_AUTO_TEST_CASE (take_difference_test)
61 {
62         dcp::order::Font A;
63         A._values["foo"] = "bar";
64         A._values["fred"] = "jim";
65
66         dcp::order::Font B;
67         B._values["foo"] = "bar";
68         B._values["sheila"] = "baz";
69
70         A.take_difference (B);
71         BOOST_REQUIRE_EQUAL (A._values.size(), 1);
72         BOOST_CHECK_EQUAL (A._values["fred"], "jim");
73 }
74
75 /** Test dcp::order::Subtitle::pull_fonts */
76 BOOST_AUTO_TEST_CASE (pull_fonts_test1)
77 {
78         shared_ptr<dcp::order::Part> root (new dcp::order::Part (shared_ptr<dcp::order::Part> ()));
79         shared_ptr<dcp::order::Subtitle> sub1 (new dcp::order::Subtitle (root, dcp::Time(), dcp::Time(), dcp::Time(), dcp::Time()));
80         root->children.push_back (sub1);
81         shared_ptr<dcp::order::Text> text1 (new dcp::order::Text (sub1, dcp::HALIGN_CENTER, 0, dcp::VALIGN_TOP, 0, dcp::DIRECTION_LTR));
82         sub1->children.push_back (text1);
83         text1->font._values["font"] = "Inconsolata";
84         text1->font._values["size"] = "42";
85
86         dcp::SubtitleAsset::pull_fonts (root);
87
88         BOOST_REQUIRE_EQUAL (sub1->font._values.size(), 2);
89         BOOST_CHECK_EQUAL (sub1->font._values["font"], "Inconsolata");
90         BOOST_CHECK_EQUAL (sub1->font._values["size"], "42");
91         BOOST_CHECK_EQUAL (text1->font._values.size(), 0);
92 }
93
94 /** Test dcp::order::Subtitle::pull_fonts */
95 BOOST_AUTO_TEST_CASE (pull_fonts_test2)
96 {
97         shared_ptr<dcp::order::Part> root (new dcp::order::Part (shared_ptr<dcp::order::Part> ()));
98         shared_ptr<dcp::order::Subtitle> sub1 (new dcp::order::Subtitle (root, dcp::Time(), dcp::Time(), dcp::Time(), dcp::Time()));
99         root->children.push_back (sub1);
100         shared_ptr<dcp::order::Text> text1 (new dcp::order::Text (sub1, dcp::HALIGN_CENTER, 0, dcp::VALIGN_TOP, 0, dcp::DIRECTION_LTR));
101         sub1->children.push_back (text1);
102         text1->font._values["font"] = "Inconsolata";
103         text1->font._values["size"] = "42";
104         shared_ptr<dcp::order::Text> text2 (new dcp::order::Text (sub1, dcp::HALIGN_CENTER, 0, dcp::VALIGN_TOP, 0, dcp::DIRECTION_LTR));
105         sub1->children.push_back (text2);
106         text2->font._values["font"] = "Inconsolata";
107         text2->font._values["size"] = "48";
108
109         dcp::SubtitleAsset::pull_fonts (root);
110
111         BOOST_REQUIRE_EQUAL (sub1->font._values.size(), 1);
112         BOOST_CHECK_EQUAL (sub1->font._values["font"], "Inconsolata");
113         BOOST_REQUIRE_EQUAL (text1->font._values.size(), 1);
114         BOOST_CHECK_EQUAL (text1->font._values["size"], "42");
115         BOOST_REQUIRE_EQUAL (text2->font._values.size(), 1);
116         BOOST_CHECK_EQUAL (text2->font._values["size"], "48");
117 }
118
119 /** Test dcp::order::Subtitle::pull_fonts */
120 BOOST_AUTO_TEST_CASE (pull_fonts_test3)
121 {
122         shared_ptr<dcp::order::Part> root (new dcp::order::Part (shared_ptr<dcp::order::Part> ()));
123         shared_ptr<dcp::order::Subtitle> sub1 (new dcp::order::Subtitle (root, dcp::Time(), dcp::Time(), dcp::Time(), dcp::Time()));
124         root->children.push_back (sub1);
125         shared_ptr<dcp::order::Text> text1 (new dcp::order::Text (sub1, dcp::HALIGN_CENTER, 0, dcp::VALIGN_TOP, 0, dcp::DIRECTION_LTR));
126         sub1->children.push_back (text1);
127         dcp::order::Font font;
128         font._values["font"] = "Inconsolata";
129         font._values["size"] = "42";
130         shared_ptr<dcp::order::String> string1 (new dcp::order::String (text1, font, "Hello world"));
131         text1->children.push_back (string1);
132
133         dcp::SubtitleAsset::pull_fonts (root);
134
135         BOOST_REQUIRE_EQUAL (sub1->font._values.size(), 2);
136         BOOST_CHECK_EQUAL (sub1->font._values["font"], "Inconsolata");
137         BOOST_CHECK_EQUAL (sub1->font._values["size"], "42");
138 }
139
140 /** Write some subtitle content as Interop XML and check that it is right */
141 BOOST_AUTO_TEST_CASE (write_interop_subtitle_test)
142 {
143         dcp::InteropSubtitleAsset c;
144         c.set_reel_number ("1");
145         c.set_language ("EN");
146         c.set_movie_title ("Test");
147
148         c.add (
149                 dcp::SubtitleString (
150                         string ("Frutiger"),
151                         false,
152                         false,
153                         false,
154                         dcp::Colour (255, 255, 255),
155                         48,
156                         1.0,
157                         dcp::Time (0, 4,  9, 22, 24),
158                         dcp::Time (0, 4, 11, 22, 24),
159                         0,
160                         dcp::HALIGN_CENTER,
161                         0.8,
162                         dcp::VALIGN_TOP,
163                         dcp::DIRECTION_LTR,
164                         "Hello world",
165                         dcp::NONE,
166                         dcp::Colour (0, 0, 0),
167                         dcp::Time (0, 0, 0, 0, 24),
168                         dcp::Time (0, 0, 0, 0, 24)
169                         )
170                 );
171
172         c.add (
173                 dcp::SubtitleString (
174                         boost::optional<string> (),
175                         true,
176                         true,
177                         true,
178                         dcp::Colour (128, 0, 64),
179                         91,
180                         1.0,
181                         dcp::Time (5, 41,  0, 21, 24),
182                         dcp::Time (6, 12, 15, 21, 24),
183                         0,
184                         dcp::HALIGN_CENTER,
185                         0.4,
186                         dcp::VALIGN_BOTTOM,
187                         dcp::DIRECTION_LTR,
188                         "What's going on",
189                         dcp::BORDER,
190                         dcp::Colour (1, 2, 3),
191                         dcp::Time (1, 2, 3, 4, 24),
192                         dcp::Time (5, 6, 7, 8, 24)
193                         )
194                 );
195
196         c._id = "a6c58cff-3e1e-4b38-acec-a42224475ef6";
197
198         check_xml (
199                 "<DCSubtitle Version=\"1.0\">"
200                   "<SubtitleID>a6c58cff-3e1e-4b38-acec-a42224475ef6</SubtitleID>"
201                   "<MovieTitle>Test</MovieTitle>"
202                   "<ReelNumber>1</ReelNumber>"
203                   "<Language>EN</Language>"
204                   "<Font AspectAdjust=\"1.0\" Color=\"FFFFFFFF\" Effect=\"none\" EffectColor=\"FF000000\" Id=\"Frutiger\" Italic=\"no\" Script=\"normal\" Size=\"48\" Underlined=\"no\" Weight=\"normal\">"
205                     "<Subtitle SpotNumber=\"1\" TimeIn=\"00:04:09:229\" TimeOut=\"00:04:11:229\" FadeUpTime=\"0\" FadeDownTime=\"0\">"
206                       "<Text VAlign=\"top\" VPosition=\"80\">Hello world</Text>"
207                     "</Subtitle>"
208                   "</Font>"
209                   "<Font AspectAdjust=\"1.0\" Color=\"FF800040\" Effect=\"border\" EffectColor=\"FF010203\" Italic=\"yes\" Script=\"normal\" Size=\"91\" Underlined=\"yes\" Weight=\"bold\">"
210                     "<Subtitle SpotNumber=\"2\" TimeIn=\"05:41:00:219\" TimeOut=\"06:12:15:219\" FadeUpTime=\"930792\" FadeDownTime=\"4591834\">"
211                       "<Text VAlign=\"bottom\" VPosition=\"40\">What's going on</Text>"
212                     "</Subtitle>"
213                   "</Font>"
214                 "</DCSubtitle>",
215                 c.xml_as_string (),
216                 list<string> ()
217                 );
218 }
219
220 /** Write some subtitle content as Interop XML and check that it is right.
221  *  This test includes some horizontal alignment.
222  */
223 BOOST_AUTO_TEST_CASE (write_interop_subtitle_test2)
224 {
225         dcp::InteropSubtitleAsset c;
226         c.set_reel_number ("1");
227         c.set_language ("EN");
228         c.set_movie_title ("Test");
229
230         c.add (
231                 dcp::SubtitleString (
232                         string ("Frutiger"),
233                         false,
234                         false,
235                         false,
236                         dcp::Colour (255, 255, 255),
237                         48,
238                         1.0,
239                         dcp::Time (0, 4,  9, 22, 24),
240                         dcp::Time (0, 4, 11, 22, 24),
241                         -0.2,
242                         dcp::HALIGN_CENTER,
243                         0.8,
244                         dcp::VALIGN_TOP,
245                         dcp::DIRECTION_LTR,
246                         "Hello world",
247                         dcp::NONE,
248                         dcp::Colour (0, 0, 0),
249                         dcp::Time (0, 0, 0, 0, 24),
250                         dcp::Time (0, 0, 0, 0, 24)
251                         )
252                 );
253
254         c.add (
255                 dcp::SubtitleString (
256                         boost::optional<string> (),
257                         true,
258                         true,
259                         true,
260                         dcp::Colour (128, 0, 64),
261                         91,
262                         1.0,
263                         dcp::Time (5, 41,  0, 21, 24),
264                         dcp::Time (6, 12, 15, 21, 24),
265                         -0.2,
266                         dcp::HALIGN_CENTER,
267                         0.4,
268                         dcp::VALIGN_BOTTOM,
269                         dcp::DIRECTION_LTR,
270                         "What's going on",
271                         dcp::BORDER,
272                         dcp::Colour (1, 2, 3),
273                         dcp::Time (1, 2, 3, 4, 24),
274                         dcp::Time (5, 6, 7, 8, 24)
275                         )
276                 );
277
278         c._id = "a6c58cff-3e1e-4b38-acec-a42224475ef6";
279
280         check_xml (
281                 "<DCSubtitle Version=\"1.0\">"
282                   "<SubtitleID>a6c58cff-3e1e-4b38-acec-a42224475ef6</SubtitleID>"
283                   "<MovieTitle>Test</MovieTitle>"
284                   "<ReelNumber>1</ReelNumber>"
285                   "<Language>EN</Language>"
286                   "<Font AspectAdjust=\"1.0\" Color=\"FFFFFFFF\" Effect=\"none\" EffectColor=\"FF000000\" Id=\"Frutiger\" Italic=\"no\" Script=\"normal\" Size=\"48\" Underlined=\"no\" Weight=\"normal\">"
287                     "<Subtitle SpotNumber=\"1\" TimeIn=\"00:04:09:229\" TimeOut=\"00:04:11:229\" FadeUpTime=\"0\" FadeDownTime=\"0\">"
288                       "<Text HPosition=\"-20\" VAlign=\"top\" VPosition=\"80\">Hello world</Text>"
289                     "</Subtitle>"
290                   "</Font>"
291                   "<Font AspectAdjust=\"1.0\" Color=\"FF800040\" Effect=\"border\" EffectColor=\"FF010203\" Italic=\"yes\" Script=\"normal\" Size=\"91\" Underlined=\"yes\" Weight=\"bold\">"
292                     "<Subtitle SpotNumber=\"2\" TimeIn=\"05:41:00:219\" TimeOut=\"06:12:15:219\" FadeUpTime=\"930792\" FadeDownTime=\"4591834\">"
293                       "<Text HPosition=\"-20\" VAlign=\"bottom\" VPosition=\"40\">What's going on</Text>"
294                     "</Subtitle>"
295                   "</Font>"
296                 "</DCSubtitle>",
297                 c.xml_as_string (),
298                 list<string> ()
299                 );
300 }
301
302 /* Write some subtitle content as SMPTE XML and check that it is right */
303 BOOST_AUTO_TEST_CASE (write_smpte_subtitle_test)
304 {
305         dcp::SMPTESubtitleAsset c;
306         c.set_reel_number (1);
307         c.set_language ("EN");
308         c.set_content_title_text ("Test");
309         c.set_issue_date (dcp::LocalTime ("2016-04-01T03:52:00+00:00"));
310
311         c.add (
312                 dcp::SubtitleString (
313                         string ("Frutiger"),
314                         false,
315                         false,
316                         false,
317                         dcp::Colour (255, 255, 255),
318                         48,
319                         1.0,
320                         dcp::Time (0, 4,  9, 22, 24),
321                         dcp::Time (0, 4, 11, 22, 24),
322                         0,
323                         dcp::HALIGN_CENTER,
324                         0.8,
325                         dcp::VALIGN_TOP,
326                         dcp::DIRECTION_LTR,
327                         "Hello world",
328                         dcp::NONE,
329                         dcp::Colour (0, 0, 0),
330                         dcp::Time (0, 0, 0, 0, 24),
331                         dcp::Time (0, 0, 0, 0, 24)
332                         )
333                 );
334
335         c.add (
336                 dcp::SubtitleString (
337                         boost::optional<string> (),
338                         true,
339                         true,
340                         true,
341                         dcp::Colour (128, 0, 64),
342                         91,
343                         1.0,
344                         dcp::Time (5, 41,  0, 21, 24),
345                         dcp::Time (6, 12, 15, 21, 24),
346                         0,
347                         dcp::HALIGN_CENTER,
348                         0.4,
349                         dcp::VALIGN_BOTTOM,
350                         dcp::DIRECTION_RTL,
351                         "What's going on",
352                         dcp::BORDER,
353                         dcp::Colour (1, 2, 3),
354                         dcp::Time (1, 2, 3, 4, 24),
355                         dcp::Time (5, 6, 7, 8, 24)
356                         )
357                 );
358
359         c._id = "a6c58cff-3e1e-4b38-acec-a42224475ef6";
360
361         check_xml (
362                 "<?xml version=\"1.0\" encoding=\"UTF-8\"?>"
363                 "<dcst:SubtitleReel xmlns:dcst=\"http://www.smpte-ra.org/schemas/428-7/2010/DCST\" xmlns:xs=\"http://www.w3.org/2001/XMLSchema\">"
364                   "<dcst:Id>urn:uuid:a6c58cff-3e1e-4b38-acec-a42224475ef6</dcst:Id>"
365                   "<dcst:ContentTitleText>Test</dcst:ContentTitleText>"
366                   "<dcst:IssueDate>2016-04-01T03:52:00.000+00:00</dcst:IssueDate>"
367                   "<dcst:ReelNumber>1</dcst:ReelNumber>"
368                   "<dcst:Language>EN</dcst:Language>"
369                   "<dcst:EditRate>24 1</dcst:EditRate>"
370                   "<dcst:TimeCodeRate>24</dcst:TimeCodeRate>"
371                   "<dcst:SubtitleList>"
372                     "<dcst:Font AspectAdjust=\"1.0\" Color=\"FFFFFFFF\" Effect=\"none\" EffectColor=\"FF000000\" ID=\"Frutiger\" Italic=\"no\" Script=\"normal\" Size=\"48\" Underline=\"no\" Weight=\"normal\">"
373                       "<dcst:Subtitle SpotNumber=\"1\" TimeIn=\"00:04:09:22\" TimeOut=\"00:04:11:22\" FadeUpTime=\"00:00:00:00\" FadeDownTime=\"00:00:00:00\">"
374                         "<dcst:Text Valign=\"top\" Vposition=\"80\">Hello world</dcst:Text>"
375                       "</dcst:Subtitle>"
376                     "</dcst:Font>"
377                     "<dcst:Font AspectAdjust=\"1.0\" Color=\"FF800040\" Effect=\"border\" EffectColor=\"FF010203\" Italic=\"yes\" Script=\"normal\" Size=\"91\" Underline=\"yes\" Weight=\"bold\">"
378                       "<dcst:Subtitle SpotNumber=\"2\" TimeIn=\"05:41:00:21\" TimeOut=\"06:12:15:21\" FadeUpTime=\"01:02:03:04\" FadeDownTime=\"05:06:07:08\">"
379                         "<dcst:Text Valign=\"bottom\" Vposition=\"40\" Direction=\"rtl\">What's going on</dcst:Text>"
380                       "</dcst:Subtitle>"
381                     "</dcst:Font>"
382                   "</dcst:SubtitleList>"
383                 "</dcst:SubtitleReel>",
384                 c.xml_as_string (),
385                 list<string> ()
386                 );
387 }
388
389 /* Write some subtitle content as SMPTE XML and check that it is right.
390    This includes in-line font changes.
391 */
392 BOOST_AUTO_TEST_CASE (write_smpte_subtitle_test2)
393 {
394         dcp::SMPTESubtitleAsset c;
395         c.set_reel_number (1);
396         c.set_language ("EN");
397         c.set_content_title_text ("Test");
398         c.set_issue_date (dcp::LocalTime ("2016-04-01T03:52:00+00:00"));
399
400         c.add (
401                 dcp::SubtitleString (
402                         string ("Arial"),
403                         false,
404                         false,
405                         false,
406                         dcp::Colour (255, 255, 255),
407                         48,
408                         1.0,
409                         dcp::Time (0, 0, 1, 0, 24),
410                         dcp::Time (0, 0, 9, 0, 24),
411                         0,
412                         dcp::HALIGN_CENTER,
413                         0.8,
414                         dcp::VALIGN_TOP,
415                         dcp::DIRECTION_LTR,
416                         "Testing is ",
417                         dcp::NONE,
418                         dcp::Colour (0, 0, 0),
419                         dcp::Time (0, 0, 0, 0, 24),
420                         dcp::Time (0, 0, 0, 0, 24)
421                         )
422                 );
423
424         c.add (
425                 dcp::SubtitleString (
426                         string ("Arial"),
427                         true,
428                         false,
429                         false,
430                         dcp::Colour (255, 255, 255),
431                         48,
432                         1.0,
433                         dcp::Time (0, 0, 1, 0, 24),
434                         dcp::Time (0, 0, 9, 0, 24),
435                         0,
436                         dcp::HALIGN_CENTER,
437                         0.8,
438                         dcp::VALIGN_TOP,
439                         dcp::DIRECTION_LTR,
440                         "really",
441                         dcp::NONE,
442                         dcp::Colour (0, 0, 0),
443                         dcp::Time (0, 0, 0, 0, 24),
444                         dcp::Time (0, 0, 0, 0, 24)
445                         )
446                 );
447
448         c.add (
449                 dcp::SubtitleString (
450                         string ("Arial"),
451                         false,
452                         false,
453                         false,
454                         dcp::Colour (255, 255, 255),
455                         48,
456                         1.0,
457                         dcp::Time (0, 0, 1, 0, 24),
458                         dcp::Time (0, 0, 9, 0, 24),
459                         0,
460                         dcp::HALIGN_CENTER,
461                         0.8,
462                         dcp::VALIGN_TOP,
463                         dcp::DIRECTION_LTR,
464                         " fun",
465                         dcp::NONE,
466                         dcp::Colour (0, 0, 0),
467                         dcp::Time (0, 0, 0, 0, 24),
468                         dcp::Time (0, 0, 0, 0, 24)
469                         )
470                 );
471
472         c.add (
473                 dcp::SubtitleString (
474                         string ("Arial"),
475                         false,
476                         false,
477                         false,
478                         dcp::Colour (255, 255, 255),
479                         48,
480                         1.0,
481                         dcp::Time (0, 0, 1, 0, 24),
482                         dcp::Time (0, 0, 9, 0, 24),
483                         0,
484                         dcp::HALIGN_CENTER,
485                         0.9,
486                         dcp::VALIGN_TOP,
487                         dcp::DIRECTION_LTR,
488                         "This is the ",
489                         dcp::NONE,
490                         dcp::Colour (0, 0, 0),
491                         dcp::Time (0, 0, 0, 0, 24),
492                         dcp::Time (0, 0, 0, 0, 24)
493                         )
494                 );
495
496         c.add (
497                 dcp::SubtitleString (
498                         string ("Arial"),
499                         true,
500                         false,
501                         false,
502                         dcp::Colour (255, 255, 255),
503                         48,
504                         1.0,
505                         dcp::Time (0, 0, 1, 0, 24),
506                         dcp::Time (0, 0, 9, 0, 24),
507                         0,
508                         dcp::HALIGN_CENTER,
509                         0.9,
510                         dcp::VALIGN_TOP,
511                         dcp::DIRECTION_LTR,
512                         "second",
513                         dcp::NONE,
514                         dcp::Colour (0, 0, 0),
515                         dcp::Time (0, 0, 0, 0, 24),
516                         dcp::Time (0, 0, 0, 0, 24)
517                         )
518                 );
519
520         c.add (
521                 dcp::SubtitleString (
522                         string ("Arial"),
523                         false,
524                         false,
525                         false,
526                         dcp::Colour (255, 255, 255),
527                         48,
528                         1.0,
529                         dcp::Time (0, 0, 1, 0, 24),
530                         dcp::Time (0, 0, 9, 0, 24),
531                         0,
532                         dcp::HALIGN_CENTER,
533                         0.9,
534                         dcp::VALIGN_TOP,
535                         dcp::DIRECTION_LTR,
536                         " line",
537                         dcp::NONE,
538                         dcp::Colour (0, 0, 0),
539                         dcp::Time (0, 0, 0, 0, 24),
540                         dcp::Time (0, 0, 0, 0, 24)
541                         )
542                 );
543
544         c._id = "a6c58cff-3e1e-4b38-acec-a42224475ef6";
545
546         check_xml (
547                 c.xml_as_string (),
548                 "<?xml version=\"1.0\" encoding=\"UTF-8\"?>"
549                 "<dcst:SubtitleReel xmlns:dcst=\"http://www.smpte-ra.org/schemas/428-7/2010/DCST\" xmlns:xs=\"http://www.w3.org/2001/XMLSchema\">"
550                   "<dcst:Id>urn:uuid:a6c58cff-3e1e-4b38-acec-a42224475ef6</dcst:Id>"
551                   "<dcst:ContentTitleText>Test</dcst:ContentTitleText>"
552                   "<dcst:IssueDate>2016-04-01T03:52:00.000+00:00</dcst:IssueDate>"
553                   "<dcst:ReelNumber>1</dcst:ReelNumber>"
554                   "<dcst:Language>EN</dcst:Language>"
555                   "<dcst:EditRate>24 1</dcst:EditRate>"
556                   "<dcst:TimeCodeRate>24</dcst:TimeCodeRate>"
557                   "<dcst:SubtitleList>"
558                     "<dcst:Font AspectAdjust=\"1.0\" Color=\"FFFFFFFF\" Effect=\"none\" EffectColor=\"FF000000\" ID=\"Arial\" Script=\"normal\" Size=\"48\" Underline=\"no\" Weight=\"normal\">"
559                       "<dcst:Subtitle SpotNumber=\"1\" TimeIn=\"00:00:01:00\" TimeOut=\"00:00:09:00\" FadeUpTime=\"00:00:00:00\" FadeDownTime=\"00:00:00:00\">"
560                         "<dcst:Text Valign=\"top\" Vposition=\"80\">"
561                           "<dcst:Font Italic=\"no\">Testing is </dcst:Font>"
562                           "<dcst:Font Italic=\"yes\">really</dcst:Font>"
563                           "<dcst:Font Italic=\"no\"> fun</dcst:Font>"
564                         "</dcst:Text>"
565                         "<dcst:Text Valign=\"top\" Vposition=\"90\">"
566                           "<dcst:Font Italic=\"no\">This is the </dcst:Font>"
567                           "<dcst:Font Italic=\"yes\">second</dcst:Font>"
568                           "<dcst:Font Italic=\"no\"> line</dcst:Font>"
569                         "</dcst:Text>"
570                       "</dcst:Subtitle>"
571                     "</dcst:Font>"
572                   "</dcst:SubtitleList>"
573                 "</dcst:SubtitleReel>",
574                 list<string> ()
575                 );
576 }