projects
/
dcpomatic.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Assorted image subtitle fixes.
[dcpomatic.git]
/
src
/
lib
/
dcp_decoder.cc
diff --git
a/src/lib/dcp_decoder.cc
b/src/lib/dcp_decoder.cc
index bf016ef877bb11990bccf83a01821459cecb5a71..ab0df8a8641d660315be9cc7068a6243896c0ba9 100644
(file)
--- a/
src/lib/dcp_decoder.cc
+++ b/
src/lib/dcp_decoder.cc
@@
-17,6
+17,11
@@
*/
*/
+#include "dcp_decoder.h"
+#include "dcp_content.h"
+#include "j2k_image_proxy.h"
+#include "image.h"
+#include "config.h"
#include <dcp/dcp.h>
#include <dcp/cpl.h>
#include <dcp/reel.h>
#include <dcp/dcp.h>
#include <dcp/cpl.h>
#include <dcp/reel.h>
@@
-27,22
+32,16
@@
#include <dcp/mono_picture_frame.h>
#include <dcp/stereo_picture_frame.h>
#include <dcp/sound_frame.h>
#include <dcp/mono_picture_frame.h>
#include <dcp/stereo_picture_frame.h>
#include <dcp/sound_frame.h>
-#include "dcp_decoder.h"
-#include "dcp_content.h"
-#include "j2k_image_proxy.h"
-#include "image.h"
-#include "config.h"
using std::list;
using std::cout;
using boost::shared_ptr;
using boost::dynamic_pointer_cast;
using std::list;
using std::cout;
using boost::shared_ptr;
using boost::dynamic_pointer_cast;
-DCPDecoder::DCPDecoder (shared_ptr<const DCPContent> c
, shared_ptr<Log> log
)
+DCPDecoder::DCPDecoder (shared_ptr<const DCPContent> c)
: VideoDecoder (c)
, AudioDecoder (c)
, SubtitleDecoder (c)
: VideoDecoder (c)
, AudioDecoder (c)
, SubtitleDecoder (c)
- , _log (log)
, _dcp_content (c)
{
dcp::DCP dcp (c->directory ());
, _dcp_content (c)
{
dcp::DCP dcp (c->directory ());
@@
-50,7
+49,7
@@
DCPDecoder::DCPDecoder (shared_ptr<const DCPContent> c, shared_ptr<Log> log)
if (c->kdm ()) {
dcp.add (dcp::DecryptedKDM (c->kdm().get (), Config::instance()->decryption_private_key ()));
}
if (c->kdm ()) {
dcp.add (dcp::DecryptedKDM (c->kdm().get (), Config::instance()->decryption_private_key ()));
}
-
assert
(dcp.cpls().size() == 1);
+
DCPOMATIC_ASSERT
(dcp.cpls().size() == 1);
_reels = dcp.cpls().front()->reels ();
_reel = _reels.begin ();
}
_reels = dcp.cpls().front()->reels ();
_reel = _reels.begin ();
}
@@
-71,15
+70,15
@@
DCPDecoder::pass ()
shared_ptr<dcp::StereoPictureMXF> stereo = dynamic_pointer_cast<dcp::StereoPictureMXF> (mxf);
int64_t const entry_point = (*_reel)->main_picture()->entry_point ();
if (mono) {
shared_ptr<dcp::StereoPictureMXF> stereo = dynamic_pointer_cast<dcp::StereoPictureMXF> (mxf);
int64_t const entry_point = (*_reel)->main_picture()->entry_point ();
if (mono) {
- video (shared_ptr<ImageProxy> (new J2KImageProxy (mono->get_frame (entry_point + frame), mxf->size()
, _log
)), frame);
+ video (shared_ptr<ImageProxy> (new J2KImageProxy (mono->get_frame (entry_point + frame), mxf->size())), frame);
} else {
video (
} else {
video (
- shared_ptr<ImageProxy> (new J2KImageProxy (stereo->get_frame (entry_point + frame), mxf->size(), dcp::EYE_LEFT
, _log
)),
+ shared_ptr<ImageProxy> (new J2KImageProxy (stereo->get_frame (entry_point + frame), mxf->size(), dcp::EYE_LEFT)),
frame
);
video (
frame
);
video (
- shared_ptr<ImageProxy> (new J2KImageProxy (stereo->get_frame (entry_point + frame), mxf->size(), dcp::EYE_RIGHT
, _log
)),
+ shared_ptr<ImageProxy> (new J2KImageProxy (stereo->get_frame (entry_point + frame), mxf->size(), dcp::EYE_RIGHT)),
frame
);
}
frame
);
}
@@
-134,7
+133,14
@@
DCPDecoder::seek (ContentTime t, bool accurate)
list<ContentTimePeriod>
list<ContentTimePeriod>
-DCPDecoder::subtitles_during (ContentTimePeriod, bool starting) const
+DCPDecoder::image_subtitles_during (ContentTimePeriod, bool) const
+{
+ return list<ContentTimePeriod> ();
+}
+
+list<ContentTimePeriod>
+DCPDecoder::text_subtitles_during (ContentTimePeriod, bool) const
{
{
+ /* XXX */
return list<ContentTimePeriod> ();
}
return list<ContentTimePeriod> ();
}