diff options
| author | Carl Hetherington <cth@carlh.net> | 2013-01-17 19:44:58 +0000 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2013-01-17 19:44:58 +0000 |
| commit | 369ba52fe8b3ddeda734692541471c402016a18d (patch) | |
| tree | f140d572d97f1bb27d0713160247457c767cc101 /src/util.h | |
| parent | 62ee85a258aa9329544d8542dfbcc40ce8177a7a (diff) | |
Use new Size struct.
Diffstat (limited to 'src/util.h')
| -rw-r--r-- | src/util.h | 23 |
1 files changed, 22 insertions, 1 deletions
@@ -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 |
