Use a template as a basis for Frames.
[libdcp.git] / src / sound_frame.h
index 3cd3246b71009cd85b4f9e2cee92882bc7db481d..2b78c8e1d1116ae2e4ad600c838882d919e8ecfc 100644 (file)
 #ifndef LIBDCP_SOUND_FRAME_H
 #define LIBDCP_SOUND_FRAME_H
 
-#include <boost/noncopyable.hpp>
-#include <boost/filesystem.hpp>
-#include <stdint.h>
-#include <string>
-
-namespace ASDCP {
-       namespace PCM {
-               class FrameBuffer;
-               class MXFReader;
-       }
-       class AESDecContext;
-}
+#include "frame.h"
+#include <asdcp/AS_DCP.h>
 
 namespace dcp {
 
-class DecryptionContext;
-
-/** @class SoundFrame
- *  @brief One &lsquo;frame&rsquo; of sound data from a SoundAsset.
- */
-class SoundFrame : public boost::noncopyable
-{
-public:
-       ~SoundFrame ();
-
-       uint8_t const * data () const;
-       int size () const;
-
-private:
-       friend class SoundAssetReader;
-
-       SoundFrame (ASDCP::PCM::MXFReader* reader, int n, boost::shared_ptr<DecryptionContext>);
-
-       /** a buffer to hold the frame */
-       ASDCP::PCM::FrameBuffer* _buffer;
-};
+typedef Frame<ASDCP::PCM::MXFReader, ASDCP::PCM::FrameBuffer> SoundFrame;
 
 }