Some comments.
authorCarl Hetherington <cth@carlh.net>
Fri, 29 May 2015 09:36:56 +0000 (10:36 +0100)
committerCarl Hetherington <cth@carlh.net>
Fri, 29 May 2015 09:37:47 +0000 (10:37 +0100)
src/chromaticity.h
src/colour_conversion.h
src/exceptions.h
src/load_font_node.h
src/mono_picture_mxf_writer.h
src/smpte_load_font_node.h
src/sound_mxf_writer.h
src/transfer_function.h

index 89b719361cf2578a7bb5cab740238ccf0b543cd2..1cf68248573550915bccc734c88ad58555e75af4 100644 (file)
 
 */
 
+/** @file  src/chromaticity.h
+ *  @brief Chromaticity class.
+ */
+
 #ifndef DCP_CHROMATICITY_H
 #define DCP_CHROMATICITY_H
 
@@ -24,6 +28,9 @@
 
 namespace dcp {
 
+/** @class Chromaticity
+ *  @brief A representation of a x,y,z chromaticity, where z = 1 - x - y
+ */
 class Chromaticity
 {
 public:
@@ -36,7 +43,7 @@ public:
                : x (x_)
                , y (y_)
        {}
-               
+
        double x;
        double y;
 
@@ -44,6 +51,7 @@ public:
                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;
        }
index 939b0d2bebd7fb10bfd54b7f87b51b483eb87a6a..1f824c81329f22e4e72fa95edd627f2f129d520d 100644 (file)
 
 */
 
+/** @file  src/colour_conversion.h
+ *  @brief ColourConversion class.
+ */
+
 #ifndef DCP_COLOUR_CONVERSION_H
 #define DCP_COLOUR_CONVERSION_H
 
@@ -35,6 +39,10 @@ enum YUVToRGB {
        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:
@@ -132,7 +140,9 @@ 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;
@@ -140,6 +150,7 @@ protected:
        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;
 };
 
index 9b2617eee3d7c85d1b39595ffbc1d09dad177233..e613c980d037c872d52177b24499d77a6b1c2cba 100644 (file)
@@ -29,6 +29,9 @@
 namespace dcp
 {
 
+/** @class StringError
+ *  @brief An exception that uses a std::string to store its error message.
+ */
 class StringError : public std::exception
 {
 public:
@@ -159,13 +162,20 @@ 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:
index 24f193bde9d396371c5159f2441366122a79d11c..58e5920a3e1e342880a6ad1c8ab3a56fa28100a6 100644 (file)
 
 */
 
+/** @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:
index 065171c2f3e8ff9005d6842628a06e1413830a46..7cad54e0226dea84c11921b0849dcec5a1bfc7f3 100644 (file)
@@ -38,7 +38,7 @@ namespace dcp {
  *
  *  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.
index 1ca7786a1aa38d278581be13a1d91824d394aa1e..a150d9bec3a245537d66201e69b846fae2cf3e17 100644 (file)
 
 */
 
+/** @file  src/smpte_load_font_node.h
+ *  @brief SMPTELoadFontNode class.
+ */
+
 #include "load_font_node.h"
 #include <boost/shared_ptr.hpp>
 #include <boost/optional.hpp>
@@ -27,6 +31,9 @@ namespace cxml {
 
 namespace dcp {
        
+/** @class SMPTELoadFontNode
+ *  @brief Parser for LoadFont nodes from SMPTE subtitle XML.
+ */
 class SMPTELoadFontNode : public LoadFontNode
 {
 public:
index 4f60074c1e91c825b2d824a93de926fc9e4c9642..d79c60db492142669303fdf14c676ee7d545e4ca 100644 (file)
 
 */
 
+/** @file  src/sound_mxf_writer.h
+ *  @brief SoundMXFWriter class.
+ */
+
 #include "mxf_writer.h"
 #include "types.h"
 #include <boost/shared_ptr.hpp>
@@ -27,6 +31,15 @@ namespace dcp {
 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:
index 7f7187b577a4083da5ece6c7bf994864f0a7a612..c8248ccebd04181593b2f00f9e801aaf45368a78 100644 (file)
 
 */
 
+/** @file  src/transfer_function.h
+ *  @brief TransferFunction class.
+ */
+
 #ifndef LIBDCP_TRANSFER_FUNCTION_H
 #define LIBDCP_TRANSFER_FUNCTION_H
 
@@ -27,6 +31,9 @@
 
 namespace dcp {
 
+/** @class TransferFunction
+ *  @brief A transfer function represented by a lookup table.
+ */
 class TransferFunction : public boost::noncopyable
 {
 public:
@@ -38,6 +45,7 @@ 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: