projects
/
dcpomatic.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Use a struct rather than a std::pair as the return type from ImageProxy::image.
[dcpomatic.git]
/
src
/
lib
/
raw_image_proxy.cc
diff --git
a/src/lib/raw_image_proxy.cc
b/src/lib/raw_image_proxy.cc
index 6ebcee60c9d1c135822a8426fd3d49d7f5cec98a..5bd8c4811306feea406d5e023dfe3e0cbd706780 100644
(file)
--- 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.
This file is part of DCP-o-matic.
@@
-31,6
+31,8
@@
extern "C" {
#include "i18n.h"
using std::string;
#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;
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);
}
_image->read_from_socket (socket);
}
-shared_ptr<Image>
-RawImageProxy::image (optional<dcp::
NoteHandler
>) const
+ImageProxy::Result
+RawImageProxy::image (optional<dcp::
Size
>) const
{
{
- return
_image
;
+ return
Result (_image, 0)
;
}
void
}
void
@@
-81,11
+83,11
@@
RawImageProxy::same (shared_ptr<const ImageProxy> other) const
return false;
}
return false;
}
- return (*_image.get()) == (*rp->image().get());
+ return (*_image.get()) == (*rp->image().
image.
get());
}
}
-
AVPixelForma
t
-RawImageProxy::
pixel_format
() const
+
size_
t
+RawImageProxy::
memory_used
() const
{
{
- return _image->
pixel_format
();
+ return _image->
memory_used
();
}
}