summaryrefslogtreecommitdiff
path: root/src/lib/raw_image_proxy.cc
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2018-04-13 23:23:00 +0100
committerCarl Hetherington <cth@carlh.net>2018-04-13 23:23:00 +0100
commit0ff4fa6058b305476e7bc60c590acb6135c49b1c (patch)
tree1ea7e181846964bd1bab52bbfafc118f49b584f8 /src/lib/raw_image_proxy.cc
parent9106e6ed551b13e1b7c7ee2088d54ce0ae430bcf (diff)
Account for J2K decoding at lower-than-maximum resolution when croppingv2.13.14
the resulting images; fixes #1274.
Diffstat (limited to 'src/lib/raw_image_proxy.cc')
-rw-r--r--src/lib/raw_image_proxy.cc10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/lib/raw_image_proxy.cc b/src/lib/raw_image_proxy.cc
index 094b50d05..c3b565f3c 100644
--- a/src/lib/raw_image_proxy.cc
+++ b/src/lib/raw_image_proxy.cc
@@ -1,5 +1,5 @@
/*
- Copyright (C) 2014 Carl Hetherington <cth@carlh.net>
+ Copyright (C) 2014-2018 Carl Hetherington <cth@carlh.net>
This file is part of DCP-o-matic.
@@ -31,6 +31,8 @@ extern "C" {
#include "i18n.h"
using std::string;
+using std::pair;
+using std::make_pair;
using boost::shared_ptr;
using boost::dynamic_pointer_cast;
using boost::optional;
@@ -52,10 +54,10 @@ RawImageProxy::RawImageProxy (shared_ptr<cxml::Node> xml, shared_ptr<Socket> soc
_image->read_from_socket (socket);
}
-shared_ptr<Image>
+pair<shared_ptr<Image>, int>
RawImageProxy::image (optional<dcp::NoteHandler>, optional<dcp::Size>) const
{
- return _image;
+ return make_pair (_image, 0);
}
void
@@ -81,7 +83,7 @@ RawImageProxy::same (shared_ptr<const ImageProxy> other) const
return false;
}
- return (*_image.get()) == (*rp->image().get());
+ return (*_image.get()) == (*rp->image().first.get());
}
AVPixelFormat