*/
+/** @file src/chromaticity.h
+ * @brief Chromaticity class.
+ */
+
#ifndef DCP_CHROMATICITY_H
#define DCP_CHROMATICITY_H
namespace dcp {
+/** @class Chromaticity
+ * @brief A representation of a x,y,z chromaticity, where z = 1 - x - y
+ */
class Chromaticity
{
public:
: x (x_)
, y (y_)
{}
-
+
double x;
double y;
return 1 - x - y;
}
+ /** @return true if this Chromaticity's x and y are within epsilon of other */
bool about_equal (Chromaticity const & other, float epsilon) const {
return std::fabs (x - other.x) < epsilon && std::fabs (y - other.y) < epsilon;
}
*/
+/** @file src/colour_conversion.h
+ * @brief ColourConversion class.
+ */
+
#ifndef DCP_COLOUR_CONVERSION_H
#define DCP_COLOUR_CONVERSION_H
YUV_TO_RGB_COUNT
};
+/** @class ColourConversion
+ * @brief A representation of all the parameters involved the colourspace conversion
+ * of a YUV image to XYZ (via RGB).
+ */
class ColourConversion
{
public:
static ColourConversion const & p3_to_xyz ();
protected:
+ /** Input transfer function (probably a gamma function, or something similar) */
boost::shared_ptr<const TransferFunction> _in;
+ /** Conversion to use from YUV to RGB */
YUVToRGB _yuv_to_rgb;
Chromaticity _red;
Chromaticity _green;
Chromaticity _white;
/** White point that we are adjusting to using a Bradford matrix */
boost::optional<Chromaticity> _adjusted_white;
+ /** Output transfer function (probably an inverse gamma function, or something similar) */
boost::shared_ptr<const TransferFunction> _out;
};
namespace dcp
{
+/** @class StringError
+ * @brief An exception that uses a std::string to store its error message.
+ */
class StringError : public std::exception
{
public:
TimeFormatError (std::string bad_time);
};
+/** @class NotEncryptedError
+ * @brief An error raised when creating a DecryptedKDM object for assets that are not
+ * encrypted.
+ */
class NotEncryptedError : public StringError
{
public:
NotEncryptedError (std::string const & what);
~NotEncryptedError () throw () {}
};
-
+
+/** @class ProgrammingError
+ * @brief An exception thrown when a DCP_ASSERT fails; something that should not happen.
+ */
class ProgrammingError : public StringError
{
public:
*/
+/** @file src/load_font_node.h
+ * @brief LoadFontNode class.
+ */
+
#include <string>
namespace dcp {
+/** @class LoadFontNode
+ * @brief Parser for LoadFont nodes from subtitle XML.
+ */
class LoadFontNode
{
public:
*
* Objects of this class can only be created with MonoPictureMXF::start_write().
*
- * Frames can be written to the MonoPictureAsset by calling write() with a JPEG2000 image
+ * Frames can be written to the MonoPictureMXF by calling write() with a JPEG2000 image
* (a verbatim .j2c file). finalize() must be called after the last frame has been written.
* The action of finalize() can't be done in MonoPictureAssetWriter's destructor as it may
* throw an exception.
*/
+/** @file src/smpte_load_font_node.h
+ * @brief SMPTELoadFontNode class.
+ */
+
#include "load_font_node.h"
#include <boost/shared_ptr.hpp>
#include <boost/optional.hpp>
namespace dcp {
+/** @class SMPTELoadFontNode
+ * @brief Parser for LoadFont nodes from SMPTE subtitle XML.
+ */
class SMPTELoadFontNode : public LoadFontNode
{
public:
*/
+/** @file src/sound_mxf_writer.h
+ * @brief SoundMXFWriter class.
+ */
+
#include "mxf_writer.h"
#include "types.h"
#include <boost/shared_ptr.hpp>
class SoundFrame;
class SoundMXF;
+/** @class SoundMXFWriter
+ * @brief A helper class for writing to SoundMXFs.
+ *
+ * Objects of this class can only be created with SoundMXF::start_write().
+ *
+ * Sound samples can be written to the SoundMXF by calling write() with
+ * a buffer of float values. finalize() must be called after the last samples
+ * have been written.
+ */
class SoundMXFWriter : public MXFWriter
{
public:
*/
+/** @file src/transfer_function.h
+ * @brief TransferFunction class.
+ */
+
#ifndef LIBDCP_TRANSFER_FUNCTION_H
#define LIBDCP_TRANSFER_FUNCTION_H
namespace dcp {
+/** @class TransferFunction
+ * @brief A transfer function represented by a lookup table.
+ */
class TransferFunction : public boost::noncopyable
{
public:
virtual bool about_equal (boost::shared_ptr<const TransferFunction> other, double epsilon) const = 0;
protected:
+ /** Make a LUT and return an array allocated by new */
virtual double * make_lut (int bit_depth, bool inverse) const = 0;
private: