projects
/
dcpomatic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
308fb04
)
A number of unit test fixes.
author
Carl Hetherington
<cth@carlh.net>
Fri, 2 Feb 2018 21:56:27 +0000
(21:56 +0000)
committer
Carl Hetherington
<cth@carlh.net>
Fri, 2 Feb 2018 21:56:27 +0000
(21:56 +0000)
test/image_test.cc
patch
|
blob
|
history
test/import_dcp_test.cc
patch
|
blob
|
history
test/player_test.cc
patch
|
blob
|
history
test/reels_test.cc
patch
|
blob
|
history
test/repeat_frame_test.cc
patch
|
blob
|
history
test/skip_frame_test.cc
patch
|
blob
|
history
test/srt_subtitle_test.cc
patch
|
blob
|
history
diff --git
a/test/image_test.cc
b/test/image_test.cc
index 299ef2e51d381e7c6002e271707490b24c34a313..7780c94cc4f428ef77e30729469bb7efe5724a1a 100644
(file)
--- a/
test/image_test.cc
+++ b/
test/image_test.cc
@@
-194,14
+194,14
@@
BOOST_AUTO_TEST_CASE (merge_test1)
{
int const stride = 48 * 4;
{
int const stride = 48 * 4;
- shared_ptr<Image> A (new Image (AV_PIX_FMT_
RGB
A, dcp::Size (48, 48), false));
+ shared_ptr<Image> A (new Image (AV_PIX_FMT_
BGR
A, dcp::Size (48, 48), false));
A->make_transparent ();
uint8_t* a = A->data()[0];
for (int y = 0; y < 48; ++y) {
uint8_t* p = a + y * stride;
for (int x = 0; x < 16; ++x) {
A->make_transparent ();
uint8_t* a = A->data()[0];
for (int y = 0; y < 48; ++y) {
uint8_t* p = a + y * stride;
for (int x = 0; x < 16; ++x) {
- /*
red
*/
+ /*
blue
*/
p[x * 4] = 255;
/* opaque */
p[x * 4 + 3] = 255;
p[x * 4] = 255;
/* opaque */
p[x * 4 + 3] = 255;
@@
-219,21
+219,21
@@
BOOST_AUTO_TEST_CASE (merge_test1)
/** Test merge (list<PositionImage>) with two images */
BOOST_AUTO_TEST_CASE (merge_test2)
{
/** Test merge (list<PositionImage>) with two images */
BOOST_AUTO_TEST_CASE (merge_test2)
{
- shared_ptr<Image> A (new Image (AV_PIX_FMT_
RGB
A, dcp::Size (48, 1), false));
+ shared_ptr<Image> A (new Image (AV_PIX_FMT_
BGR
A, dcp::Size (48, 1), false));
A->make_transparent ();
uint8_t* a = A->data()[0];
for (int x = 0; x < 16; ++x) {
A->make_transparent ();
uint8_t* a = A->data()[0];
for (int x = 0; x < 16; ++x) {
- /*
red
*/
+ /*
blue
*/
a[x * 4] = 255;
/* opaque */
a[x * 4 + 3] = 255;
}
a[x * 4] = 255;
/* opaque */
a[x * 4 + 3] = 255;
}
- shared_ptr<Image> B (new Image (AV_PIX_FMT_
RGB
A, dcp::Size (48, 1), false));
+ shared_ptr<Image> B (new Image (AV_PIX_FMT_
BGR
A, dcp::Size (48, 1), false));
B->make_transparent ();
uint8_t* b = B->data()[0];
for (int x = 0; x < 16; ++x) {
B->make_transparent ();
uint8_t* b = B->data()[0];
for (int x = 0; x < 16; ++x) {
- /*
blue
*/
+ /*
red
*/
b[(x + 32) * 4 + 2] = 255;
/* opaque */
b[(x + 32) * 4 + 3] = 255;
b[(x + 32) * 4 + 2] = 255;
/* opaque */
b[(x + 32) * 4 + 3] = 255;
diff --git
a/test/import_dcp_test.cc
b/test/import_dcp_test.cc
index 163a3a4a966054dc200943cc94572e1016f8dc27..403c1c992320edf01e635f5d6457048f79748ea3 100644
(file)
--- a/
test/import_dcp_test.cc
+++ b/
test/import_dcp_test.cc
@@
-45,6
+45,7
@@
BOOST_AUTO_TEST_CASE (import_dcp_test)
A->set_container (Ratio::from_id ("185"));
A->set_dcp_content_type (DCPContentType::from_isdcf_name ("TLR"));
A->set_name ("frobozz");
A->set_container (Ratio::from_id ("185"));
A->set_dcp_content_type (DCPContentType::from_isdcf_name ("TLR"));
A->set_name ("frobozz");
+ A->set_interop (false);
shared_ptr<FFmpegContent> c (new FFmpegContent (A, "test/data/test.mp4"));
A->examine_and_add_content (c);
shared_ptr<FFmpegContent> c (new FFmpegContent (A, "test/data/test.mp4"));
A->examine_and_add_content (c);
@@
-72,6
+73,7
@@
BOOST_AUTO_TEST_CASE (import_dcp_test)
B->set_container (Ratio::from_id ("185"));
B->set_dcp_content_type (DCPContentType::from_isdcf_name ("TLR"));
B->set_name ("frobozz");
B->set_container (Ratio::from_id ("185"));
B->set_dcp_content_type (DCPContentType::from_isdcf_name ("TLR"));
B->set_name ("frobozz");
+ B->set_interop (false);
shared_ptr<DCPContent> d (new DCPContent (B, "build/test/import_dcp_test/" + A->dcp_name()));
d->add_kdm (kdm);
shared_ptr<DCPContent> d (new DCPContent (B, "build/test/import_dcp_test/" + A->dcp_name()));
d->add_kdm (kdm);
diff --git
a/test/player_test.cc
b/test/player_test.cc
index 0ddb67afcb70b817e718803190cc1ca0aa25ff93..1580d5902e3a4da40e3ad32c7b21593cc5fa16ee 100644
(file)
--- a/
test/player_test.cc
+++ b/
test/player_test.cc
@@
-92,6
+92,7
@@
BOOST_AUTO_TEST_CASE (player_black_fill_test)
film->set_name ("black_fill_test");
film->set_container (Ratio::from_id ("185"));
film->set_sequence (false);
film->set_name ("black_fill_test");
film->set_container (Ratio::from_id ("185"));
film->set_sequence (false);
+ film->set_interop (false);
shared_ptr<ImageContent> contentA (new ImageContent (film, "test/data/simple_testcard_640x480.png"));
shared_ptr<ImageContent> contentB (new ImageContent (film, "test/data/simple_testcard_640x480.png"));
shared_ptr<ImageContent> contentA (new ImageContent (film, "test/data/simple_testcard_640x480.png"));
shared_ptr<ImageContent> contentB (new ImageContent (film, "test/data/simple_testcard_640x480.png"));
diff --git
a/test/reels_test.cc
b/test/reels_test.cc
index bd7b1c06a05c8c9f6372fa9b2d604aa804797444..9e8e120a6822072054a75a8e811ccabb12d5f178 100644
(file)
--- a/
test/reels_test.cc
+++ b/
test/reels_test.cc
@@
-91,6
+91,7
@@
BOOST_AUTO_TEST_CASE (reels_test2)
shared_ptr<Film> film = new_test_film ("reels_test2");
film->set_name ("reels_test2");
film->set_container (Ratio::from_id ("185"));
shared_ptr<Film> film = new_test_film ("reels_test2");
film->set_name ("reels_test2");
film->set_container (Ratio::from_id ("185"));
+ film->set_interop (false);
film->set_dcp_content_type (DCPContentType::from_isdcf_name ("TST"));
{
film->set_dcp_content_type (DCPContentType::from_isdcf_name ("TST"));
{
@@
-194,6
+195,7
@@
BOOST_AUTO_TEST_CASE (reels_test4)
film->set_container (Ratio::from_id ("185"));
film->set_dcp_content_type (DCPContentType::from_isdcf_name ("TST"));
film->set_reel_type (REELTYPE_BY_VIDEO_CONTENT);
film->set_container (Ratio::from_id ("185"));
film->set_dcp_content_type (DCPContentType::from_isdcf_name ("TST"));
film->set_reel_type (REELTYPE_BY_VIDEO_CONTENT);
+ film->set_interop (false);
/* 4 piece of 1s-long content */
shared_ptr<ImageContent> content[4];
/* 4 piece of 1s-long content */
shared_ptr<ImageContent> content[4];
diff --git
a/test/repeat_frame_test.cc
b/test/repeat_frame_test.cc
index 24075991cad5a2b0e124c708aab6e7bb82d19103..fd64ba018cbf47746798220f5438de28d9b17c5b 100644
(file)
--- a/
test/repeat_frame_test.cc
+++ b/
test/repeat_frame_test.cc
@@
-42,6
+42,7
@@
BOOST_AUTO_TEST_CASE (repeat_frame_test)
film->set_name ("repeat_frame_test");
film->set_container (Ratio::from_id ("185"));
film->set_dcp_content_type (DCPContentType::from_isdcf_name ("TST"));
film->set_name ("repeat_frame_test");
film->set_container (Ratio::from_id ("185"));
film->set_dcp_content_type (DCPContentType::from_isdcf_name ("TST"));
+ film->set_interop (false);
shared_ptr<FFmpegContent> c (new FFmpegContent (film, "test/data/red_24.mp4"));
film->examine_and_add_content (c);
shared_ptr<FFmpegContent> c (new FFmpegContent (film, "test/data/red_24.mp4"));
film->examine_and_add_content (c);
diff --git
a/test/skip_frame_test.cc
b/test/skip_frame_test.cc
index 97aadb2f74f8f5eff66c109c83f02d5151fdc0bf..fdea35849eafdf21c156b575afe7c1241ec634b1 100644
(file)
--- a/
test/skip_frame_test.cc
+++ b/
test/skip_frame_test.cc
@@
-42,6
+42,7
@@
BOOST_AUTO_TEST_CASE (skip_frame_test)
film->set_name ("skip_frame_test");
film->set_container (Ratio::from_id ("185"));
film->set_dcp_content_type (DCPContentType::from_isdcf_name ("TST"));
film->set_name ("skip_frame_test");
film->set_container (Ratio::from_id ("185"));
film->set_dcp_content_type (DCPContentType::from_isdcf_name ("TST"));
+ film->set_interop (false);
shared_ptr<FFmpegContent> c (new FFmpegContent (film, "test/data/count300bd48.m2ts"));
film->examine_and_add_content (c);
shared_ptr<FFmpegContent> c (new FFmpegContent (film, "test/data/count300bd48.m2ts"));
film->examine_and_add_content (c);
diff --git
a/test/srt_subtitle_test.cc
b/test/srt_subtitle_test.cc
index b6df6e393751f12d695e02cc00ca626162a0fc5d..025972da8ddab4f4195acd76181235b19a1fa855 100644
(file)
--- a/
test/srt_subtitle_test.cc
+++ b/
test/srt_subtitle_test.cc
@@
-46,6
+46,7
@@
BOOST_AUTO_TEST_CASE (srt_subtitle_test)
film->set_dcp_content_type (DCPContentType::from_isdcf_name ("TLR"));
film->set_name ("frobozz");
film->set_audio_channels (6);
film->set_dcp_content_type (DCPContentType::from_isdcf_name ("TLR"));
film->set_name ("frobozz");
film->set_audio_channels (6);
+ film->set_interop (false);
shared_ptr<TextSubtitleContent> content (new TextSubtitleContent (film, "test/data/subrip2.srt"));
film->examine_and_add_content (content);
wait_for_jobs ();
shared_ptr<TextSubtitleContent> content (new TextSubtitleContent (film, "test/data/subrip2.srt"));
film->examine_and_add_content (content);
wait_for_jobs ();
@@
-67,6
+68,7
@@
BOOST_AUTO_TEST_CASE (srt_subtitle_test2)
film->set_dcp_content_type (DCPContentType::from_isdcf_name ("TLR"));
film->set_name ("frobozz");
film->set_audio_channels (6);
film->set_dcp_content_type (DCPContentType::from_isdcf_name ("TLR"));
film->set_name ("frobozz");
film->set_audio_channels (6);
+ film->set_interop (false);
shared_ptr<TextSubtitleContent> content (new TextSubtitleContent (film, "test/data/subrip2.srt"));
film->examine_and_add_content (content);
wait_for_jobs ();
shared_ptr<TextSubtitleContent> content (new TextSubtitleContent (film, "test/data/subrip2.srt"));
film->examine_and_add_content (content);
wait_for_jobs ();
@@
-118,6
+120,7
@@
BOOST_AUTO_TEST_CASE (srt_subtitle_test3)
film->set_name ("frobozz");
film->set_interop (true);
film->set_audio_channels (6);
film->set_name ("frobozz");
film->set_interop (true);
film->set_audio_channels (6);
+ film->set_interop (false);
shared_ptr<TextSubtitleContent> content (new TextSubtitleContent (film, private_data / "Ankoemmling_short.srt"));
film->examine_and_add_content (content);
wait_for_jobs ();
shared_ptr<TextSubtitleContent> content (new TextSubtitleContent (film, private_data / "Ankoemmling_short.srt"));
film->examine_and_add_content (content);
wait_for_jobs ();
@@
-138,6
+141,7
@@
BOOST_AUTO_TEST_CASE (srt_subtitle_test4)
film->set_container (Ratio::from_id ("185"));
film->set_dcp_content_type (DCPContentType::from_isdcf_name ("TLR"));
film->set_name ("frobozz");
film->set_container (Ratio::from_id ("185"));
film->set_dcp_content_type (DCPContentType::from_isdcf_name ("TLR"));
film->set_name ("frobozz");
+ film->set_interop (false);
shared_ptr<TextSubtitleContent> content (new TextSubtitleContent (film, "test/data/subrip2.srt"));
content->subtitle->set_use (true);
content->subtitle->set_burn (false);
shared_ptr<TextSubtitleContent> content (new TextSubtitleContent (film, "test/data/subrip2.srt"));
content->subtitle->set_use (true);
content->subtitle->set_burn (false);