summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2015-06-21 01:15:32 +0100
committerCarl Hetherington <cth@carlh.net>2015-06-21 01:15:32 +0100
commite60bb3e51bd1508b149e6b8f6608f09b5196ae26 (patch)
treea7a5b937c9ae138d4eebca8d5130d308bf9ae420 /test
parentf07d5125a7b609320682689abe40781f096ca25e (diff)
No-op: remove all trailing whitespace.
Diffstat (limited to 'test')
-rw-r--r--test/audio_analysis_test.cc10
-rw-r--r--test/audio_buffers_test.cc8
-rw-r--r--test/audio_decoder_test.cc6
-rw-r--r--test/audio_delay_test.cc4
-rw-r--r--test/audio_filter_test.cc6
-rw-r--r--test/client_server_test.cc8
-rw-r--r--test/ffmpeg_audio_test.cc6
-rw-r--r--test/ffmpeg_dcp_test.cc6
-rw-r--r--test/ffmpeg_decoder_seek_test.cc8
-rw-r--r--test/ffmpeg_decoder_sequential_test.cc10
-rw-r--r--test/file_group_test.cc2
-rw-r--r--test/film_metadata_test.cc2
-rw-r--r--test/frame_rate_test.cc18
-rw-r--r--test/image_test.cc6
-rw-r--r--test/isdcf_name_test.cc4
-rw-r--r--test/make_black_test.cc4
-rw-r--r--test/pixel_formats_test.cc2
-rw-r--r--test/play_test.cc4
-rw-r--r--test/player_test.cc2
-rw-r--r--test/recover_test.cc2
-rw-r--r--test/repeat_frame_test.cc2
-rw-r--r--test/resampler_test.cc6
-rw-r--r--test/scaling_test.cc2
-rw-r--r--test/seek_zero_test.cc2
-rw-r--r--test/silence_padding_test.cc6
-rw-r--r--test/srt_subtitle_test.cc2
-rw-r--r--test/stream_test.cc4
-rw-r--r--test/test.cc18
-rw-r--r--test/threed_test.cc2
-rw-r--r--test/util_test.cc4
-rw-r--r--test/video_content_scale_test.cc8
-rw-r--r--test/video_decoder_fill_test.cc8
32 files changed, 91 insertions, 91 deletions
diff --git a/test/audio_analysis_test.cc b/test/audio_analysis_test.cc
index 6c05916ab..94ad96a29 100644
--- a/test/audio_analysis_test.cc
+++ b/test/audio_analysis_test.cc
@@ -44,9 +44,9 @@ BOOST_AUTO_TEST_CASE (audio_analysis_serialisation_test)
{
int const channels = 3;
int const points = 4096;
-
+
srand (1);
-
+
AudioAnalysis a (3);
for (int i = 0; i < channels; ++i) {
for (int j = 0; j < points; ++j) {
@@ -74,7 +74,7 @@ BOOST_AUTO_TEST_CASE (audio_analysis_serialisation_test)
BOOST_CHECK_CLOSE (p[AudioPoint::RMS], random_float (), 1);
}
}
-
+
BOOST_CHECK (b.peak ());
BOOST_CHECK_CLOSE (b.peak().get(), peak, 1);
BOOST_CHECK (b.peak_time ());
@@ -114,7 +114,7 @@ BOOST_AUTO_TEST_CASE (audio_analysis_negative_delay_test)
c->set_audio_delay (-250);
film->examine_and_add_content (c);
wait_for_jobs ();
-
+
shared_ptr<AnalyseAudioJob> job (new AnalyseAudioJob (film));
job->Finished.connect (boost::bind (&finished));
JobManager::instance()->add (job);
@@ -129,7 +129,7 @@ BOOST_AUTO_TEST_CASE (audio_analysis_test2)
shared_ptr<AudioContent> c (new FFmpegContent (film, private_data / "3d_thx_broadway_2010_lossless.m2ts"));
film->examine_and_add_content (c);
wait_for_jobs ();
-
+
shared_ptr<AnalyseAudioJob> job (new AnalyseAudioJob (film));
job->Finished.connect (boost::bind (&finished));
JobManager::instance()->add (job);
diff --git a/test/audio_buffers_test.cc b/test/audio_buffers_test.cc
index 15f918470..044a4c22c 100644
--- a/test/audio_buffers_test.cc
+++ b/test/audio_buffers_test.cc
@@ -98,7 +98,7 @@ BOOST_AUTO_TEST_CASE (audio_buffers_make_silent_test)
random_fill (buffers);
buffers.make_silent ();
-
+
for (int i = 0; i < 9933; ++i) {
for (int c = 0; c < 9; ++c) {
BOOST_CHECK_EQUAL (buffers.data(c)[i], 0);
@@ -248,7 +248,7 @@ BOOST_AUTO_TEST_CASE (audio_buffers_move)
for (int i = 0; i < from * 7; ++i) {
random_float ();
}
-
+
random_check (buffers, to, frames);
}
@@ -258,7 +258,7 @@ BOOST_AUTO_TEST_CASE (audio_buffers_accumulate_channel)
AudioBuffers a (3, 256);
srand (38);
random_fill (a);
-
+
AudioBuffers b (3, 256);
random_fill (b);
@@ -283,7 +283,7 @@ BOOST_AUTO_TEST_CASE (audio_buffers_accumulate_frames)
AudioBuffers a (3, 256);
srand (38);
random_fill (a);
-
+
AudioBuffers b (3, 256);
random_fill (b);
diff --git a/test/audio_decoder_test.cc b/test/audio_decoder_test.cc
index cd86b73e7..6816c1fbb 100644
--- a/test/audio_decoder_test.cc
+++ b/test/audio_decoder_test.cc
@@ -49,7 +49,7 @@ public:
DCPTime full_length () const {
return DCPTime::from_seconds (float (audio_length()) / audio_stream()->frame_rate ());
}
-
+
Frame audio_length () const {
return rint (61.2942 * audio_stream()->frame_rate ());
}
@@ -125,7 +125,7 @@ BOOST_AUTO_TEST_CASE (audio_decoder_get_audio_test)
content.reset (new TestAudioContent (film));
decoder.reset (new TestAudioDecoder (content));
-
+
/* Simple reads */
check (0, 48000);
check (44, 9123);
@@ -136,7 +136,7 @@ BOOST_AUTO_TEST_CASE (audio_decoder_get_audio_test)
Frame const from = content->resampled_audio_frame_rate() * 61;
Frame const length = content->resampled_audio_frame_rate() * 4;
ContentAudio ca = get (from, length);
-
+
for (int i = 0; i < content->audio_stream()->channels(); ++i) {
for (int j = 0; j < ca.audio->frames(); ++j) {
BOOST_REQUIRE_EQUAL (ca.audio->data(i)[j], j + from);
diff --git a/test/audio_delay_test.cc b/test/audio_delay_test.cc
index 05384873f..d36672a8a 100644
--- a/test/audio_delay_test.cc
+++ b/test/audio_delay_test.cc
@@ -44,7 +44,7 @@ static
void test_audio_delay (int delay_in_ms)
{
BOOST_TEST_MESSAGE ("Testing delay of " << delay_in_ms);
-
+
string const film_name = "audio_delay_test_" + lexical_cast<string> (delay_in_ms);
shared_ptr<Film> film = new_test_film (film_name);
film->set_dcp_content_type (DCPContentType::from_isdcf_name ("FTR"));
@@ -78,7 +78,7 @@ void test_audio_delay (int delay_in_ms)
while (n < sound_asset->asset()->intrinsic_duration()) {
shared_ptr<const dcp::SoundFrame> sound_frame = sound_asset->asset()->get_frame (frame++);
uint8_t const * d = sound_frame->data ();
-
+
for (int i = 0; i < sound_frame->size(); i += (3 * sound_asset->asset()->channels())) {
/* Mono input so it will appear on centre */
diff --git a/test/audio_filter_test.cc b/test/audio_filter_test.cc
index bcd16fd4e..c3d799b3b 100644
--- a/test/audio_filter_test.cc
+++ b/test/audio_filter_test.cc
@@ -40,7 +40,7 @@ audio_filter_impulse_test_one (AudioFilter& f, int block_size, int num_blocks)
}
shared_ptr<AudioBuffers> out = f.run (in);
-
+
for (int j = 0; j < out->frames(); ++j) {
BOOST_CHECK_EQUAL (out->data()[0][j], c + j);
}
@@ -77,7 +77,7 @@ BOOST_AUTO_TEST_CASE (audio_filter_impulse_input_test)
shared_ptr<AudioBuffers> in (new AudioBuffers (1, 1751));
in->make_silent ();
in->data(0)[0] = 1;
-
+
shared_ptr<AudioBuffers> out = lpf.run (in);
for (int j = 0; j < out->frames(); ++j) {
if (j <= lpf._M) {
@@ -92,7 +92,7 @@ BOOST_AUTO_TEST_CASE (audio_filter_impulse_input_test)
in.reset (new AudioBuffers (1, 9133));
in->make_silent ();
in->data(0)[0] = 1;
-
+
out = hpf.run (in);
for (int j = 0; j < out->frames(); ++j) {
if (j <= hpf._M) {
diff --git a/test/client_server_test.cc b/test/client_server_test.cc
index 511e913d9..e97abcec5 100644
--- a/test/client_server_test.cc
+++ b/test/client_server_test.cc
@@ -45,7 +45,7 @@ do_remote_encode (shared_ptr<DCPVideo> frame, ServerDescription description, Dat
{
Data remotely_encoded;
BOOST_CHECK_NO_THROW (remotely_encoded = frame->encode_remotely (description));
-
+
BOOST_CHECK_EQUAL (locally_encoded.size(), remotely_encoded.size());
BOOST_CHECK_EQUAL (memcmp (locally_encoded.data().get(), remotely_encoded.data().get(), locally_encoded.size()), 0);
}
@@ -54,7 +54,7 @@ BOOST_AUTO_TEST_CASE (client_server_test_rgb)
{
shared_ptr<Image> image (new Image (PIX_FMT_RGB24, dcp::Size (1998, 1080), true));
uint8_t* p = image->data()[0];
-
+
for (int y = 0; y < 1080; ++y) {
uint8_t* q = p;
for (int x = 0; x < 1998; ++x) {
@@ -109,7 +109,7 @@ BOOST_AUTO_TEST_CASE (client_server_test_rgb)
);
Data locally_encoded = frame->encode_locally (boost::bind (&Log::dcp_log, log.get(), _1, _2));
-
+
Server* server = new Server (log, true);
new thread (boost::bind (&Server::run, server, 2));
@@ -191,7 +191,7 @@ BOOST_AUTO_TEST_CASE (client_server_test_yuv)
);
Data locally_encoded = frame->encode_locally (boost::bind (&Log::dcp_log, log.get(), _1, _2));
-
+
Server* server = new Server (log, true);
new thread (boost::bind (&Server::run, server, 2));
diff --git a/test/ffmpeg_audio_test.cc b/test/ffmpeg_audio_test.cc
index 2c34c437d..aac32edc0 100644
--- a/test/ffmpeg_audio_test.cc
+++ b/test/ffmpeg_audio_test.cc
@@ -47,7 +47,7 @@ BOOST_AUTO_TEST_CASE (ffmpeg_audio_test)
film->examine_and_add_content (c);
wait_for_jobs ();
-
+
c->set_scale (VideoContentScale (Ratio::from_id ("185")));
film->set_container (Ratio::from_id ("185"));
@@ -76,7 +76,7 @@ BOOST_AUTO_TEST_CASE (ffmpeg_audio_test)
while (n < sound_asset->asset()->intrinsic_duration()) {
shared_ptr<const dcp::SoundFrame> sound_frame = sound_asset->asset()->get_frame (frame++);
uint8_t const * d = sound_frame->data ();
-
+
for (int i = 0; i < sound_frame->size(); i += (3 * sound_asset->asset()->channels())) {
if (sound_asset->asset()->channels() > 0) {
@@ -90,7 +90,7 @@ BOOST_AUTO_TEST_CASE (ffmpeg_audio_test)
int const sample = d[i + 2] | (d[i + 3] << 8);
BOOST_CHECK_EQUAL (sample, 0);
}
-
+
if (sound_asset->asset()->channels() > 2) {
/* Mono input so it will appear on centre */
int const sample = d[i + 7] | (d[i + 8] << 8);
diff --git a/test/ffmpeg_dcp_test.cc b/test/ffmpeg_dcp_test.cc
index 797af8736..ce8ecad6b 100644
--- a/test/ffmpeg_dcp_test.cc
+++ b/test/ffmpeg_dcp_test.cc
@@ -42,9 +42,9 @@ BOOST_AUTO_TEST_CASE (ffmpeg_dcp_test)
film->examine_and_add_content (c);
wait_for_jobs ();
-
+
c->set_scale (VideoContentScale (Ratio::from_id ("185")));
-
+
film->set_container (Ratio::from_id ("185"));
film->set_dcp_content_type (DCPContentType::from_pretty_name ("Test"));
film->make_dcp ();
@@ -70,6 +70,6 @@ BOOST_AUTO_TEST_CASE (ffmpeg_have_dcp_test)
if (i != boost::filesystem::directory_iterator ()) {
boost::filesystem::remove (i->path ());
}
-
+
BOOST_CHECK (film->cpls().empty());
}
diff --git a/test/ffmpeg_decoder_seek_test.cc b/test/ffmpeg_decoder_seek_test.cc
index c15bf8c98..c81b7389c 100644
--- a/test/ffmpeg_decoder_seek_test.cc
+++ b/test/ffmpeg_decoder_seek_test.cc
@@ -59,7 +59,7 @@ test (boost::filesystem::path file, vector<int> frames)
}
shared_ptr<Film> film = new_test_film ("ffmpeg_decoder_seek_test_" + file.string());
- shared_ptr<FFmpegContent> content (new FFmpegContent (film, path));
+ shared_ptr<FFmpegContent> content (new FFmpegContent (film, path));
film->examine_and_add_content (content);
wait_for_jobs ();
shared_ptr<Log> log (new NullLog);
@@ -73,7 +73,7 @@ test (boost::filesystem::path file, vector<int> frames)
BOOST_AUTO_TEST_CASE (ffmpeg_decoder_seek_test)
{
vector<int> frames;
-
+
frames.clear ();
frames.push_back (0);
frames.push_back (42);
@@ -82,13 +82,13 @@ BOOST_AUTO_TEST_CASE (ffmpeg_decoder_seek_test)
test ("boon_telly.mkv", frames);
test ("Sintel_Trailer1.480p.DivX_Plus_HD.mkv", frames);
-
+
frames.clear ();
frames.push_back (15);
frames.push_back (42);
frames.push_back (999);
frames.push_back (15);
-
+
test ("prophet_clip.mkv", frames);
}
diff --git a/test/ffmpeg_decoder_sequential_test.cc b/test/ffmpeg_decoder_sequential_test.cc
index 98c7bf9e2..601dd1c59 100644
--- a/test/ffmpeg_decoder_sequential_test.cc
+++ b/test/ffmpeg_decoder_sequential_test.cc
@@ -46,25 +46,25 @@ test (boost::filesystem::path file, float fps, int gaps)
}
shared_ptr<Film> film = new_test_film ("ffmpeg_decoder_seek_test_" + file.string());
- shared_ptr<FFmpegContent> content (new FFmpegContent (film, path));
+ shared_ptr<FFmpegContent> content (new FFmpegContent (film, path));
film->examine_and_add_content (content);
wait_for_jobs ();
shared_ptr<Log> log (new NullLog);
shared_ptr<FFmpegDecoder> decoder (new FFmpegDecoder (content, log));
BOOST_CHECK_CLOSE (decoder->video_content()->video_frame_rate(), fps, 0.01);
-
+
Frame const N = decoder->video_content()->video_length();
-#ifdef DCPOMATIC_DEBUG
+#ifdef DCPOMATIC_DEBUG
decoder->test_gaps = 0;
-#endif
+#endif
for (Frame i = 0; i < N; ++i) {
list<ContentVideo> v;
v = decoder->get_video (i, true);
BOOST_CHECK_EQUAL (v.size(), 1U);
BOOST_CHECK_EQUAL (v.front().frame, i);
}
-#ifdef DCPOMATIC_DEBUG
+#ifdef DCPOMATIC_DEBUG
BOOST_CHECK_EQUAL (decoder->test_gaps, gaps);
#endif
}
diff --git a/test/file_group_test.cc b/test/file_group_test.cc
index 888834511..9b70bd944 100644
--- a/test/file_group_test.cc
+++ b/test/file_group_test.cc
@@ -36,7 +36,7 @@ BOOST_AUTO_TEST_CASE (file_group_test)
for (int i = 0; i < 65536; ++i) {
data[i] = rand() & 0xff;
}
-
+
int const num_files = 4;
int length[] = {
diff --git a/test/film_metadata_test.cc b/test/film_metadata_test.cc
index 851fffb3f..423bc4ccc 100644
--- a/test/film_metadata_test.cc
+++ b/test/film_metadata_test.cc
@@ -58,7 +58,7 @@ BOOST_AUTO_TEST_CASE (film_metadata_test)
BOOST_CHECK_EQUAL (g->name(), "fred");
BOOST_CHECK_EQUAL (g->dcp_content_type(), DCPContentType::from_pretty_name ("Short"));
BOOST_CHECK_EQUAL (g->container(), Ratio::from_id ("185"));
-
+
g->write_metadata ();
check_xml ("test/data/metadata.xml.ref", dir.string() + "/metadata.xml", ignore);
}
diff --git a/test/frame_rate_test.cc b/test/frame_rate_test.cc
index cf3dc2612..0133431ee 100644
--- a/test/frame_rate_test.cc
+++ b/test/frame_rate_test.cc
@@ -43,9 +43,9 @@ BOOST_AUTO_TEST_CASE (best_dcp_frame_rate_test_single)
shared_ptr<FFmpegContent> content (new FFmpegContent (film, "test/data/test.mp4"));
film->add_content (content);
wait_for_jobs ();
-
+
/* Run some tests with a limited range of allowed rates */
-
+
std::list<int> afr;
afr.push_back (24);
afr.push_back (25);
@@ -60,7 +60,7 @@ BOOST_AUTO_TEST_CASE (best_dcp_frame_rate_test_single)
BOOST_CHECK_EQUAL (frc.repeat, 1);
BOOST_CHECK_EQUAL (frc.change_speed, false);
BOOST_CHECK_CLOSE (frc.speed_up, 1, 0.1);
-
+
content->_video_frame_rate = 50;
best = film->best_video_frame_rate ();
frc = FrameRateChange (50, best);
@@ -96,7 +96,7 @@ BOOST_AUTO_TEST_CASE (best_dcp_frame_rate_test_single)
BOOST_CHECK_EQUAL (frc.repeat, 1);
BOOST_CHECK_EQUAL (frc.change_speed, true);
BOOST_CHECK_CLOSE (frc.speed_up, 30 / 29.97, 0.1);
-
+
content->_video_frame_rate = 25;
best = film->best_video_frame_rate ();
frc = FrameRateChange (25, best);
@@ -168,7 +168,7 @@ BOOST_AUTO_TEST_CASE (best_dcp_frame_rate_test_single)
BOOST_CHECK_EQUAL (frc.repeat, 1);
BOOST_CHECK_EQUAL (frc.change_speed, false);
BOOST_CHECK_CLOSE (frc.speed_up, 1, 0.1);
-
+
content->_video_frame_rate = 50;
best = film->best_video_frame_rate ();
frc = FrameRateChange (50, best);
@@ -188,7 +188,7 @@ BOOST_AUTO_TEST_CASE (best_dcp_frame_rate_test_single)
BOOST_CHECK_CLOSE (frc.speed_up, 1, 0.1);
/* Check some out-there conversions (not the best) */
-
+
frc = FrameRateChange (14.99, 24);
BOOST_CHECK_EQUAL (frc.skip, false);
BOOST_CHECK_EQUAL (frc.repeat, 2);
@@ -225,7 +225,7 @@ BOOST_AUTO_TEST_CASE (best_dcp_frame_rate_test_double)
wait_for_jobs ();
/* Run some tests with a limited range of allowed rates */
-
+
std::list<int> afr;
afr.push_back (24);
afr.push_back (25);
@@ -244,7 +244,7 @@ BOOST_AUTO_TEST_CASE (audio_sampling_rate_test)
shared_ptr<FFmpegContent> content (new FFmpegContent (film, "test/data/test.mp4"));
film->examine_and_add_content (content);
wait_for_jobs ();
-
+
std::list<int> afr;
afr.push_back (24);
afr.push_back (25);
@@ -286,7 +286,7 @@ BOOST_AUTO_TEST_CASE (audio_sampling_rate_test)
BOOST_CHECK_EQUAL (content->resampled_audio_frame_rate(), 50000);
/* Check some out-there conversions (not the best) */
-
+
content->_video_frame_rate = 14.99;
film->set_video_frame_rate (25);
stream->_frame_rate = 16000;
diff --git a/test/image_test.cc b/test/image_test.cc
index 5561f021c..21363b5ef 100644
--- a/test/image_test.cc
+++ b/test/image_test.cc
@@ -186,7 +186,7 @@ crop_scale_window_single (AVPixelFormat in_format, dcp::Size in_size, Crop crop,
}
}
}
-
+
/* Convert using separate methods */
boost::shared_ptr<Image> sep = test->crop (crop, true);
sep = sep->scale (inter_size, dcp::YUV_TO_RGB_REC601, PIX_FMT_RGB24, true);
@@ -235,7 +235,7 @@ BOOST_AUTO_TEST_CASE (crop_scale_window_test)
BOOST_AUTO_TEST_CASE (alpha_blend_test)
{
int const stride = 48 * 4;
-
+
shared_ptr<Image> A (new Image (AV_PIX_FMT_RGBA, dcp::Size (48, 48), false));
A->make_black ();
uint8_t* a = A->data()[0];
@@ -289,7 +289,7 @@ BOOST_AUTO_TEST_CASE (alpha_blend_test)
BOOST_AUTO_TEST_CASE (merge_test1)
{
int const stride = 48 * 4;
-
+
shared_ptr<Image> A (new Image (AV_PIX_FMT_RGBA, dcp::Size (48, 48), false));
A->make_transparent ();
uint8_t* a = A->data()[0];
diff --git a/test/isdcf_name_test.cc b/test/isdcf_name_test.cc
index b54ce205f..38cd54569 100644
--- a/test/isdcf_name_test.cc
+++ b/test/isdcf_name_test.cc
@@ -84,7 +84,7 @@ BOOST_AUTO_TEST_CASE (isdcf_name_test)
film->set_dcp_content_type (DCPContentType::from_isdcf_name ("XSN"));
BOOST_CHECK_EQUAL (film->isdcf_name(false), "MyNiceFilmWith_XSN-2_F-133_DE-FR_US-R_4K_DI_20140704_PP_SMPTE_VF");
-
+
/* Test 3D */
film->set_three_d (true);
@@ -123,7 +123,7 @@ BOOST_AUTO_TEST_CASE (isdcf_name_test)
BOOST_CHECK_EQUAL (film->isdcf_name(false), "LikeShouting_XSN-2_F-133_DE-FR_US-R_4K_DI_20140704_PP_SMPTE_VF");
/* Test audio channel markup */
-
+
film->set_audio_channels (6);
shared_ptr<SndfileContent> sound (new SndfileContent (film, "test/data/sine_440.wav"));
film->examine_and_add_content (sound);
diff --git a/test/make_black_test.cc b/test/make_black_test.cc
index b0243310b..ec5aa6999 100644
--- a/test/make_black_test.cc
+++ b/test/make_black_test.cc
@@ -75,13 +75,13 @@ BOOST_AUTO_TEST_CASE (make_black_test)
pix_fmts.push_back (AV_PIX_FMT_YUVA422P16LE);
pix_fmts.push_back (AV_PIX_FMT_YUVA444P16LE);
pix_fmts.push_back (AV_PIX_FMT_RGB555LE); // 46
-
+
int N = 0;
for (list<AVPixelFormat>::const_iterator i = pix_fmts.begin(); i != pix_fmts.end(); ++i) {
boost::shared_ptr<Image> foo (new Image (*i, in_size, true));
foo->make_black ();
boost::shared_ptr<Image> bar = foo->scale (out_size, dcp::YUV_TO_RGB_REC601, PIX_FMT_RGB24, true);
-
+
uint8_t* p = bar->data()[0];
for (int y = 0; y < bar->size().height; ++y) {
uint8_t* q = p;
diff --git a/test/pixel_formats_test.cc b/test/pixel_formats_test.cc
index 68d225e6e..f99bd717c 100644
--- a/test/pixel_formats_test.cc
+++ b/test/pixel_formats_test.cc
@@ -51,7 +51,7 @@ struct Case
bpp[1] = b1;
bpp[2] = b2;
}
-
+
AVPixelFormat format;
int components;
int lines[3];
diff --git a/test/play_test.cc b/test/play_test.cc
index dcf8e7f6d..8ad2180b8 100644
--- a/test/play_test.cc
+++ b/test/play_test.cc
@@ -62,7 +62,7 @@ public:
if (_queue.empty ()) {
return optional<Video> ();
}
-
+
Video v = _queue.back ();
_queue.pop_back ();
return v;
@@ -97,7 +97,7 @@ BOOST_AUTO_TEST_CASE (play_test)
wait_for_jobs ();
BOOST_CHECK_EQUAL (B->video_length_after_3d_combine(), 16);
-
+
/* Film should have been set to 25fps */
BOOST_CHECK_EQUAL (film->video_frame_rate(), 25);
diff --git a/test/player_test.cc b/test/player_test.cc
index b9038dcce..87e7fda8a 100644
--- a/test/player_test.cc
+++ b/test/player_test.cc
@@ -88,7 +88,7 @@ BOOST_AUTO_TEST_CASE (player_silence_padding_test)
shared_ptr<FFmpegContent> c (new FFmpegContent (film, "test/data/test.mp4"));
film->set_container (Ratio::from_id ("185"));
film->set_audio_channels (6);
-
+
film->examine_and_add_content (c);
wait_for_jobs ();
diff --git a/test/recover_test.cc b/test/recover_test.cc
index 07b380838..ef60a56ab 100644
--- a/test/recover_test.cc
+++ b/test/recover_test.cc
@@ -63,7 +63,7 @@ BOOST_AUTO_TEST_CASE (recover_test)
video,
"build/test/recover_test/original.mxf"
);
-
+
boost::filesystem::resize_file (video, 2 * 1024 * 1024);
film->make_dcp ();
diff --git a/test/repeat_frame_test.cc b/test/repeat_frame_test.cc
index d836fcbdd..2e325af25 100644
--- a/test/repeat_frame_test.cc
+++ b/test/repeat_frame_test.cc
@@ -45,7 +45,7 @@ BOOST_AUTO_TEST_CASE (repeat_frame_test)
wait_for_jobs ();
c->set_scale (VideoContentScale (Ratio::from_id ("185")));
-
+
film->set_video_frame_rate (48);
film->make_dcp ();
wait_for_jobs ();
diff --git a/test/resampler_test.cc b/test/resampler_test.cc
index 0fc05685b..d633f75c1 100644
--- a/test/resampler_test.cc
+++ b/test/resampler_test.cc
@@ -37,15 +37,15 @@ resampler_test_one (int from, int to)
/* 3 hours */
int64_t const N = int64_t (from) * 60 * 60 * 3;
-
+
/* XXX: no longer checks anything */
for (int64_t i = 0; i < N; i += 1000) {
shared_ptr<AudioBuffers> a (new AudioBuffers (1, 1000));
a->make_silent ();
shared_ptr<const AudioBuffers> r = resamp.run (a);
}
-}
-
+}
+
BOOST_AUTO_TEST_CASE (resampler_test)
{
resampler_test_one (44100, 48000);
diff --git a/test/scaling_test.cc b/test/scaling_test.cc
index 8d9df8977..b6b38e126 100644
--- a/test/scaling_test.cc
+++ b/test/scaling_test.cc
@@ -63,7 +63,7 @@ BOOST_AUTO_TEST_CASE (scaling_test)
film->examine_and_add_content (imc);
wait_for_jobs ();
-
+
imc->set_video_length (1);
/* F-133: 133 image in a flat container */
diff --git a/test/seek_zero_test.cc b/test/seek_zero_test.cc
index 3aef11373..7f661b21c 100644
--- a/test/seek_zero_test.cc
+++ b/test/seek_zero_test.cc
@@ -48,7 +48,7 @@ BOOST_AUTO_TEST_CASE (seek_zero_test)
film->examine_and_add_content (content);
wait_for_jobs ();
content->set_scale (VideoContentScale (Ratio::from_id ("185")));
-
+
/* Work out the first video frame index that we will be given, taking into account
* the difference between first video and first audio.
*/
diff --git a/test/silence_padding_test.cc b/test/silence_padding_test.cc
index 9a797aab5..30f7e106e 100644
--- a/test/silence_padding_test.cc
+++ b/test/silence_padding_test.cc
@@ -73,7 +73,7 @@ test_silence_padding (int channels)
while (n < sound_asset->asset()->intrinsic_duration()) {
shared_ptr<const dcp::SoundFrame> sound_frame = sound_asset->asset()->get_frame (frame++);
uint8_t const * d = sound_frame->data ();
-
+
for (int i = 0; i < sound_frame->size(); i += (3 * sound_asset->asset()->channels())) {
if (sound_asset->asset()->channels() > 0) {
@@ -87,7 +87,7 @@ test_silence_padding (int channels)
int const sample = d[i + 2] | (d[i + 3] << 8);
BOOST_CHECK_EQUAL (sample, 0);
}
-
+
if (sound_asset->asset()->channels() > 2) {
/* Mono input so it will appear on centre */
int const sample = d[i + 7] | (d[i + 8] << 8);
@@ -116,7 +116,7 @@ test_silence_padding (int channels)
++n;
}
}
-
+
}
BOOST_AUTO_TEST_CASE (silence_padding_test)
diff --git a/test/srt_subtitle_test.cc b/test/srt_subtitle_test.cc
index 2279308e1..64249a118 100644
--- a/test/srt_subtitle_test.cc
+++ b/test/srt_subtitle_test.cc
@@ -65,7 +65,7 @@ BOOST_AUTO_TEST_CASE (srt_subtitle_test2)
content->set_use_subtitles (true);
/* Use test/data/subrip2.srt as if it were a font file */
content->fonts().front()->set_file ("test/data/subrip2.srt");
-
+
film->make_dcp ();
wait_for_jobs ();
diff --git a/test/stream_test.cc b/test/stream_test.cc
index 800bbd049..ec211a929 100644
--- a/test/stream_test.cc
+++ b/test/stream_test.cc
@@ -42,7 +42,7 @@ BOOST_AUTO_TEST_CASE (stream_test)
root->add_child("Channels")->add_child_text ("2");
/* This is the state file version 5 description of the mapping */
-
+
xmlpp::Element* mapping = root->add_child("Mapping");
mapping->add_child("ContentChannels")->add_child_text ("2");
{
@@ -69,7 +69,7 @@ BOOST_AUTO_TEST_CASE (stream_test)
map->add_child("ContentIndex")->add_child_text ("1");
map->add_child("DCP")->add_child_text ("2");
}
-
+
FFmpegAudioStream a (cxml::NodePtr (new cxml::Node (root)), 5);
BOOST_CHECK_EQUAL (a.identifier(), "4");
diff --git a/test/test.cc b/test/test.cc
index bdd17e6a1..1080aec79 100644
--- a/test/test.cc
+++ b/test/test.cc
@@ -106,7 +106,7 @@ new_test_film (string name)
if (boost::filesystem::exists (p)) {
boost::filesystem::remove_all (p);
}
-
+
shared_ptr<Film> film = shared_ptr<Film> (new Film (p.string()));
film->write_metadata ();
return film;
@@ -119,7 +119,7 @@ check_audio_file (boost::filesystem::path ref, boost::filesystem::path check)
ref_info.format = 0;
SNDFILE* ref_file = sf_open (ref.string().c_str(), SFM_READ, &ref_info);
BOOST_CHECK (ref_file);
-
+
SF_INFO check_info;
check_info.format = 0;
SNDFILE* check_file = sf_open (check.string().c_str(), SFM_READ, &check_info);
@@ -134,7 +134,7 @@ check_audio_file (boost::filesystem::path ref, boost::filesystem::path check)
sf_count_t const buffer_size = 65536 * ref_info.channels;
scoped_array<int32_t> ref_buffer (new int32_t[buffer_size]);
scoped_array<int32_t> check_buffer (new int32_t[buffer_size]);
-
+
sf_count_t N = ref_info.frames;
while (N) {
sf_count_t this_time = min (buffer_size, N);
@@ -160,14 +160,14 @@ check_file (boost::filesystem::path ref, boost::filesystem::path check)
BOOST_CHECK (ref_file);
FILE* check_file = fopen_boost (check, "rb");
BOOST_CHECK (check_file);
-
+
int const buffer_size = 65536;
uint8_t* ref_buffer = new uint8_t[buffer_size];
uint8_t* check_buffer = new uint8_t[buffer_size];
SafeStringStream error;
error << "File " << check.string() << " differs from reference " << ref.string();
-
+
while (N) {
uintmax_t this_time = min (uintmax_t (buffer_size), N);
size_t r = fread (ref_buffer, 1, this_time, ref_file);
@@ -179,7 +179,7 @@ check_file (boost::filesystem::path ref, boost::filesystem::path check)
if (memcmp (ref_buffer, check_buffer, this_time)) {
break;
}
-
+
N -= this_time;
}
@@ -214,7 +214,7 @@ check_dcp (boost::filesystem::path ref, boost::filesystem::path check)
options.reel_annotation_texts_can_differ = true;
options.reel_hashes_can_differ = true;
options.issue_dates_can_differ = true;
-
+
BOOST_CHECK (ref_dcp.equals (check_dcp, options, boost::bind (note, _1, _2)));
}
@@ -291,7 +291,7 @@ wait_for_jobs ()
}
cout << "Waiting for jobs: all finished; errors=" << jm->errors() << ".\n";
-
+
if (jm->errors ()) {
int N = 0;
for (list<shared_ptr<Job> >::iterator i = jm->_jobs.begin(); i != jm->_jobs.end(); ++i) {
@@ -327,7 +327,7 @@ write_image (shared_ptr<const Image> image, boost::filesystem::path file)
using namespace MagickCore;
#else
using namespace MagickLib;
-#endif
+#endif
Magick::Image m (image->size().width, image->size().height, "ARGB", CharPixel, (void *) image->data()[0]);
m.write (file.string ());
diff --git a/test/threed_test.cc b/test/threed_test.cc
index f51a77109..a4b1566ef 100644
--- a/test/threed_test.cc
+++ b/test/threed_test.cc
@@ -42,7 +42,7 @@ BOOST_AUTO_TEST_CASE (threed_test)
wait_for_jobs ();
c->set_scale (VideoContentScale (Ratio::from_id ("185")));
-
+
film->set_container (Ratio::from_id ("185"));
film->set_dcp_content_type (DCPContentType::from_pretty_name ("Test"));
film->set_three_d (true);
diff --git a/test/util_test.cc b/test/util_test.cc
index 2a66cb855..e296229e1 100644
--- a/test/util_test.cc
+++ b/test/util_test.cc
@@ -44,7 +44,7 @@ BOOST_AUTO_TEST_CASE (md5_digest_test)
p.push_back ("test/data/md5.test2");
p.push_back ("test/data/md5.test4");
BOOST_CHECK_EQUAL (md5_digest_head_tail (p, 1024), "52ccf111e4e72b58bb7b2aaa6bd45ea5");
-
+
p.clear ();
p.push_back ("foobar");
BOOST_CHECK_THROW (md5_digest_head_tail (p, 1024), OpenFileError);
@@ -57,7 +57,7 @@ BOOST_AUTO_TEST_CASE (dcptime_round_up_test)
BOOST_CHECK_EQUAL (DCPTime (1).round_up (DCPTime::HZ / 2), DCPTime (2));
BOOST_CHECK_EQUAL (DCPTime (2).round_up (DCPTime::HZ / 2), DCPTime (2));
BOOST_CHECK_EQUAL (DCPTime (3).round_up (DCPTime::HZ / 2), DCPTime (4));
-
+
BOOST_CHECK_EQUAL (DCPTime (0).round_up (DCPTime::HZ / 42), DCPTime (0));
BOOST_CHECK_EQUAL (DCPTime (1).round_up (DCPTime::HZ / 42), DCPTime (42));
BOOST_CHECK_EQUAL (DCPTime (42).round_up (DCPTime::HZ / 42), DCPTime (42));
diff --git a/test/video_content_scale_test.cc b/test/video_content_scale_test.cc
index d2ee4c0d8..80367274d 100644
--- a/test/video_content_scale_test.cc
+++ b/test/video_content_scale_test.cc
@@ -105,7 +105,7 @@ test (dcp::Size content_size, dcp::Size display_size, dcp::Size film_size, Crop
}
BOOST_CHECK (answer == correct);
}
-
+
/* Test scale and stretch to specified ratio */
BOOST_AUTO_TEST_CASE (video_content_scale_test_to_ratio)
{
@@ -132,7 +132,7 @@ BOOST_AUTO_TEST_CASE (video_content_scale_test_to_ratio)
true,
dcp::Size (1998, 837)
);
-
+
// Flat in scope container
test (
dcp::Size (400, 200),
@@ -144,7 +144,7 @@ BOOST_AUTO_TEST_CASE (video_content_scale_test_to_ratio)
dcp::Size (1587, 858)
);
-
+
/* To player */
// Flat in flat container
@@ -168,7 +168,7 @@ BOOST_AUTO_TEST_CASE (video_content_scale_test_to_ratio)
true,
dcp::Size (185, 78)
);
-
+
// Flat in scope container
test (
dcp::Size (400, 200),
diff --git a/test/video_decoder_fill_test.cc b/test/video_decoder_fill_test.cc
index 85dafd93f..25f754853 100644
--- a/test/video_decoder_fill_test.cc
+++ b/test/video_decoder_fill_test.cc
@@ -34,7 +34,7 @@ BOOST_AUTO_TEST_CASE (video_decoder_fill_test1)
decoder.fill_2d (0, 4);
BOOST_CHECK_EQUAL (decoder._decoded_video.size(), 4U);
- list<ContentVideo>::iterator i = decoder._decoded_video.begin();
+ list<ContentVideo>::iterator i = decoder._decoded_video.begin();
for (int j = 0; j < 4; ++j) {
BOOST_CHECK_EQUAL (i->frame, j);
++i;
@@ -44,7 +44,7 @@ BOOST_AUTO_TEST_CASE (video_decoder_fill_test1)
decoder.fill_2d (0, 7);
BOOST_CHECK_EQUAL (decoder._decoded_video.size(), 7);
- i = decoder._decoded_video.begin();
+ i = decoder._decoded_video.begin();
for (int j = 0; j < 7; ++j) {
BOOST_CHECK_EQUAL (i->frame, j);
++i;
@@ -59,7 +59,7 @@ BOOST_AUTO_TEST_CASE (video_decoder_fill_test2)
decoder.fill_3d (0, 4, EYES_LEFT);
BOOST_CHECK_EQUAL (decoder._decoded_video.size(), 8);
- list<ContentVideo>::iterator i = decoder._decoded_video.begin();
+ list<ContentVideo>::iterator i = decoder._decoded_video.begin();
for (int j = 0; j < 8; ++j) {
BOOST_CHECK_EQUAL (i->frame, j / 2);
BOOST_CHECK_EQUAL (i->eyes, (j % 2) == 0 ? EYES_LEFT : EYES_RIGHT);
@@ -68,7 +68,7 @@ BOOST_AUTO_TEST_CASE (video_decoder_fill_test2)
decoder.fill_3d (0, 7, EYES_RIGHT);
BOOST_CHECK_EQUAL (decoder._decoded_video.size(), 15);
- i = decoder._decoded_video.begin();
+ i = decoder._decoded_video.begin();
for (int j = 0; j < 15; ++j) {
BOOST_CHECK_EQUAL (i->frame, j / 2);
BOOST_CHECK_EQUAL (i->eyes, (j % 2) == 0 ? EYES_LEFT : EYES_RIGHT);