Merge branch '1.0' of git.carlh.net:git/libdcp into 1.0
[libdcp.git] / src / xyz_frame.cc
index cba908836ad0b5126d884756cf370a9b84285cf4..f1c6949173cbc1edb5c7ffb14507a334daef9b62 100644 (file)
@@ -22,7 +22,7 @@
  */
 
 #include "xyz_frame.h"
-#include <cassert>
+#include "dcp_assert.h"
 #include <stdexcept>
 
 using namespace dcp;
@@ -31,7 +31,7 @@ using namespace dcp;
 XYZFrame::XYZFrame (opj_image_t* image)
        : _opj_image (image)
 {
-       assert (_opj_image->numcomps == 3);
+       DCP_ASSERT (_opj_image->numcomps == 3);
 }
 
 /** Construct a new XYZFrame with undefined contents.
@@ -72,12 +72,12 @@ XYZFrame::~XYZFrame ()
 }
 
 /** @param c Component index (0, 1 or 2)
- *  @return Pointer to the data for component c.
+ *  @return Pointer to the data for component c; 12-bit values from 0-4095.
  */
 int *
 XYZFrame::data (int c) const
 {
-       assert (c >= 0 && c < 3);
+       DCP_ASSERT (c >= 0 && c < 3);
        return _opj_image->comps[c].data;
 }