projects
/
dcpomatic.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix build.
[dcpomatic.git]
/
test
/
play_test.cc
diff --git
a/test/play_test.cc
b/test/play_test.cc
index 51e2272568acbf26a1bc321d0ad1bdf63af3bc36..bbf70781a87d4600526428055228fc54809c1c62 100644
(file)
--- a/
test/play_test.cc
+++ b/
test/play_test.cc
@@
-1,5
+1,5
@@
/*
/*
- Copyright (C) 2013 Carl Hetherington <cth@carlh.net>
+ Copyright (C) 2013
-2014
Carl Hetherington <cth@carlh.net>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@
-21,6
+21,7
@@
#include "lib/player.h"
#include "lib/ratio.h"
#include "lib/dcp_content_type.h"
#include "lib/player.h"
#include "lib/ratio.h"
#include "lib/dcp_content_type.h"
+#include "lib/player_video_frame.h"
#include "test.h"
/* This test needs stuff in Player that is only included in debug mode */
#include "test.h"
/* This test needs stuff in Player that is only included in debug mode */
@@
-43,14
+44,14
@@
public:
PlayerWrapper (shared_ptr<Player> p)
: _player (p)
{
PlayerWrapper (shared_ptr<Player> p)
: _player (p)
{
- _player->Video.connect (bind (&PlayerWrapper::process_video, this, _1, _
2, _5
));
+ _player->Video.connect (bind (&PlayerWrapper::process_video, this, _1, _
3
));
}
}
- void process_video (shared_ptr<Player
Image> i, bool
, Time t)
+ void process_video (shared_ptr<Player
VideoFrame> i
, Time t)
{
Video v;
v.content = _player->_last_video;
{
Video v;
v.content = _player->_last_video;
- v.image = i->image ();
+ v.image = i->image (
PIX_FMT_RGB24
);
v.time = t;
_queue.push_front (v);
}
v.time = t;
_queue.push_front (v);
}
@@
-81,7
+82,7
@@
private:
BOOST_AUTO_TEST_CASE (play_test)
{
shared_ptr<Film> film = new_test_film ("play_test");
BOOST_AUTO_TEST_CASE (play_test)
{
shared_ptr<Film> film = new_test_film ("play_test");
- film->set_dcp_content_type (DCPContentType::from_
dci
_name ("FTR"));
+ film->set_dcp_content_type (DCPContentType::from_
isdcf
_name ("FTR"));
film->set_container (Ratio::from_id ("185"));
film->set_name ("play_test");
film->set_container (Ratio::from_id ("185"));
film->set_name ("play_test");
@@
-119,7
+120,7
@@
BOOST_AUTO_TEST_CASE (play_test)
}
}
}
}
-
player->
seek (10 * TIME_HZ / 25, true);
+
wrap.
seek (10 * TIME_HZ / 25, true);
optional<Video> v = wrap.get_video ();
BOOST_CHECK (v);
BOOST_CHECK_EQUAL (v.get().time, 10 * TIME_HZ / 25);
optional<Video> v = wrap.get_video ();
BOOST_CHECK (v);
BOOST_CHECK_EQUAL (v.get().time, 10 * TIME_HZ / 25);