summaryrefslogtreecommitdiff
path: root/src/util.h
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2013-01-17 19:44:58 +0000
committerCarl Hetherington <cth@carlh.net>2013-01-17 19:44:58 +0000
commit369ba52fe8b3ddeda734692541471c402016a18d (patch)
treef140d572d97f1bb27d0713160247457c767cc101 /src/util.h
parent62ee85a258aa9329544d8542dfbcc40ce8177a7a (diff)
Use new Size struct.
Diffstat (limited to 'src/util.h')
-rw-r--r--src/util.h23
1 files changed, 22 insertions, 1 deletions
diff --git a/src/util.h b/src/util.h
index 721d1138..dd153cb3 100644
--- a/src/util.h
+++ b/src/util.h
@@ -17,18 +17,37 @@
*/
+#ifndef LIBDCP_UTIL_H
+#define LIBDCP_UTIL_H
+
/** @file src/util.h
* @brief Utility methods.
*/
#include <string>
#include <stdint.h>
+#include <boost/shared_ptr.hpp>
#include <openjpeg.h>
#include "types.h"
namespace libdcp {
-class ARGBFrame;
+class ARGBFrame;
+
+struct Size {
+ Size ()
+ : width (0)
+ , height (0)
+ {}
+
+ Size (int w, int h)
+ : width (w)
+ , height (h)
+ {}
+
+ int width;
+ int height;
+};
extern std::string make_uuid ();
extern std::string make_digest (std::string filename);
@@ -39,3 +58,5 @@ extern opj_image_t* decompress_j2k (uint8_t* data, int64_t size, int reduce);
extern boost::shared_ptr<ARGBFrame> xyz_to_rgb (opj_image_t* xyz_frame);
}
+
+#endif